[PATCH] 2.3.46 Scheduler Statistics tool

From: bhartner@us.ibm.com
Date: Fri Feb 25 2000 - 19:37:52 EST


After our paper on "Java, Threads, and Scheduling in Linux" was
published, there was a lot of discussion on the kernel mailing list
about scheduler alternatives. Unfortunately, as near as we could tell,
there was no good way to compare and evaluate the various proposals
that were being made. To help solve this problem, we have developed
a patch to collect a number of statistics about the scheduler. We are
providing this patch to the Linux community in order to encourage
evaluation and comparison of alternative schedulers.

The patch collects statistics on most [if not all] of the events in
the scheduler. The statistics are reported through the proc file
system (/proc/sstat).

http://oss.software.ibm.com/developerworks/opensource/linux/patches/sstat/sstat_1.0_2.3.46.tar.gz

The tar file includes the patch and an HTML document that describes
the events in detail.

The patch (a configurable option) is not meant to be turned on in
a production kernel due to overhead, but it gives you a pretty good
idea what is going on in the scheduler when running a particular
workload. Thus, it is useful for analysis of scheduler changes.

The patch also includes support for arming the P6 performance-monitoring
counters through the proc file system (/proc/perfcntr0 and
/proc/perfcntr1).

Some of the events reported :

Avg. cpu cycles a process spends on the run queue
Avg. cpu cycles a process runs for
# of priority preemptions - reschedule_idle()
# of context switches and type - schedule()
# of times switch_mm() is called to switch a memory map
# resched ipis
# times priorities are recalculated.
# timeslice preemptions

and about 15-20 other events.

Bill Hartner
IBM Linux Technology Center
bhartner@us.ibm.com

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Tue Feb 29 2000 - 21:00:14 EST