Linux Scheduler Statistics
/proc/schedstat format
version 1


Format for version 1 of schedstat:

tag 1 2 3 4 5 6 7 8 9 10 11 12
tag is cpuN or totals.

NOTE: In the sched_yield() statistics, the active queue is considered empty if it has only one process in it, since obviously the process calling sched_yield() is that process.

First four are sched_yield() statistics:

  1. # of times both the active and the expired queue were empty
  2. # of times just the active queue was empty
  3. # of times just the expired queue was empty
  4. # of times sched_yield() was called

Next three are schedule() statistics:

  1. # of times the active queue had at least one other process on it.
  2. # of times we switched to the expired queue and reused it
  3. # of times schedule() was called

Last five are statistics dealing with load_balance() (these will always be zero if CONFIG_SMP is not specified):

  1. # of times load_balance() was called at an idle tick
  2. # of times load_balance() was called from schedule()
  3. # of times load_balance() was called
  4. sum of imbalances discovered (if any) with each call to load_balance()
  5. # of times load_balance() was called when we did not find a "busiest" queue


Questions to ricklind@us.ibm.com