spdl.pipeline.ThreadStats¶
- class ThreadStats(pid: int, name: str, num_threads: int, minflt: int | None, majflt: int | None, utime: float | None, stime: float | None, voluntary_ctxt_switches: int | None, nonvoluntary_ctxt_switches: int | None, run_time: float | None, run_delay: float | None)[source]¶
Counters of the threads of one process that share a name, over the interval.
Threads are grouped by their OS name, which SPDL sets for its own threads. On Python < 3.14, other threads keep the executable’s name (e.g.
python3.12) unless named explicitly. Counters of threads that exited during the interval are counted only in the process’s totals.Added in version 0.9.0.
Attributes
Process ID.
The threads' OS name (
comm).Number of live threads with this name.
Minor page faults.
Major page faults.
CPU time in user mode, in seconds.
CPU time in kernel mode, in seconds.
Voluntary context switches.
Involuntary context switches (preemptions).
Time on a CPU, in seconds (
schedstat).Time runnable but waiting for a CPU, in seconds (
schedstat).