]> git.baikalelectronics.ru Git - kernel.git/commit
sched: high-res preemption tick
authorPeter Zijlstra <a.p.zijlstra@chello.nl>
Fri, 25 Jan 2008 20:08:29 +0000 (21:08 +0100)
committerIngo Molnar <mingo@elte.hu>
Fri, 25 Jan 2008 20:08:29 +0000 (21:08 +0100)
commitdfdceac19568f5f937e3251c838edca497e935a8
treea9ac9063eca53e4d0110e8086f55241ea70ba993
parent4e1d8aef4f0775c9954ba4cf790e0f716aab2033
sched: high-res preemption tick

Use HR-timers (when available) to deliver an accurate preemption tick.

The regular scheduler tick that runs at 1/HZ can be too coarse when nice
level are used. The fairness system will still keep the cpu utilisation 'fair'
by then delaying the task that got an excessive amount of CPU time but try to
minimize this by delivering preemption points spot-on.

The average frequency of this extra interrupt is sched_latency / nr_latency.
Which need not be higher than 1/HZ, its just that the distribution within the
sched_latency period is important.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
12 files changed:
arch/x86/kernel/entry_64.S
arch/x86/kernel/signal_32.c
arch/x86/kernel/signal_64.c
include/asm-x86/thread_info_32.h
include/asm-x86/thread_info_64.h
include/linux/hrtimer.h
include/linux/sched.h
kernel/Kconfig.hz
kernel/sched.c
kernel/sched_fair.c
kernel/sched_idletask.c
kernel/sched_rt.c