[lkml]   [2004]   [Jun]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Subject[PATCH] Single Priority Array (SPA) CPU scheduler patches for 2.6.7
Are available as a single gzipped patch at:


or as a series of patches to be applied in sequence (for easier
understanding) at:

replaces the active and expired array with a single array and adds a
promotion mechanism to avoid starvation,
replaces the interactive priority bonus mechanism with a simpler one,
adds a throughput bonus mechanism,
adds reporting of scheduling statistics including time spent on the run
queue waiting for CPU access (to enable analysis of scheduling
behaviour), and
adds a directory /proc/sys/kernel/cpusched to /proc/sys and a number of
attributes that can be used to control the scheduler as follows:

base_promotion_interval -- (milliseconds) controls the interval between
successive promotions (is multiplied by the number of active tasks on
the CPU in question) NB no promotion occurs if there are less than 2
active tasks

time_slice -- (milliseconds) the size of the time slice (i.e. how long
it will be allowed to hold the CPU before it is kicked off to allow
other tasks a chance to run) that is allocated to a task when it becomes
active or finishes a time slice. (min is 1 millisec and max is 1 second).

max_ia_bonus -- (a value between 0 and 10) that determines the maximum
interactive bonus that a task can acquire

ia_threshold -- (parts per thousand) is the sleep to (sleep + on_cpu)
ratio above which a task will have its interactive bonus increased
asymptotically towards the maximum

cpu_hog_threshold -- (parts per thousand) is the usage rate above which
a task will be considered a CPU hog and start to lose interactive bonus
points if it has any

max_tpt_bonus -- (a value between 0 and 9) that determines the maximum
throughput bonus that tasks may be awarded

log_at_exit - (0 or 1) turns off/on the logging of tasks' scheduling
statistics at exit. This feature is useful for determining the
scheduling characteristics of relatively short lived tasks that run as
part of some larger job such as a kernel build where trying to get time
series data is impractical.

A primitive Python/Glade/GTK GUI for manipulating these parameters is
available at:


In addition, a version of Con Kolivas's staircase scheduler with
promotion and scheduler statistics added is available as a single patch at:


and as multiple patches at:


and a primitive GUI for manipulating its control parameters is at:


Comments and feedback welcome,
Peter Williams

"Learning, n. The kind of ignorance distinguishing the studious."
-- Ambrose Bierce

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 14:03    [W:0.058 / U:1.868 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site