Module process_tree

Module process_tree 

Source
Expand description

Process tree traversal: BFS from a root PID to collect all descendant PIDs. Used by the sysinfo loop to aggregate CPU/memory across entire process trees.

Constants§

MAX_PIDS_PER_BLOCK
Maximum number of PIDs to track per block (safety cap against pathological trees).

Functions§

collect_descendants
Returns the root PID plus all descendant PIDs via BFS, capped at max_pids.