Skip to main content

web_cpu_static

Function web_cpu_static 

Source
pub fn web_cpu_static() -> Vec<PerCpuMetrics>
Expand description

Per-CPU static data for the web UI, seeded once at attach.

Runs Topology::new() a second time (besides init_topology()) and reports, per online CPU: the maximum operating frequency (Cpu.max_freq, in kHz), the LLC domain id (from the same plan_llcs mapping the placement path uses) and whether the CPU shares its core with a sibling thread (the plan_sibling_table test sibling[i] != i, the same pairing the wakeup-preference path consumes). The dynamic per-CPU fields are filled by the web-metrics poll from the BPF per-CPU maps.

Best-effort like the rest of the topology discovery: any failure yields an empty list and the web UI shows no per-CPU cards rather than aborting the scheduler.