pub fn stall_predicate(samples: &[SchedSample]) -> boolExpand description
Stall predicate: returns true when samples.len() >= STALL_WINDOW AND every consecutive pair has both nr_switches
delta == 0 AND sum_exec_runtime_ns delta == 0. A window
shorter than STALL_WINDOW never fires (insufficient signal).
Extracted as a free function so a unit test can exercise the
predicate directly with synthetic SchedSample sequences
without spinning up the polling thread.