Skip to content

Commit

Permalink
Add comment regd why fields are added at runtime
Browse files Browse the repository at this point in the history
  • Loading branch information
mmynk committed Oct 3, 2023
1 parent 4436736 commit 3ab76fa
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions below/dump/src/system.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ impl Dumper for System {

if self.opts.detail || self.opts.everything {
// If detail is set, add per-cpu fields.
// The fields need to be added at runtime because we cannot know the number of CPUs in the model statically.
for key in model.system.cpus.keys() {
for subquery_id in &enum_iterator::all::<model::SingleCpuModelFieldId>().collect::<Vec<_>>() {
let value = subquery_id.clone();
Expand Down

0 comments on commit 3ab76fa

Please sign in to comment.