diff options
author | Peter Zijlstra <peterz@infradead.org> | 2009-09-16 06:31:31 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-09-17 04:17:25 -0400 |
commit | ad4b78bbcbab66998b05d422ac6106b645796e54 (patch) | |
tree | 45f3561f4bd6b886948a3b0eea64edab9bab9eda /include | |
parent | eb24073bc1fe3e569a855cf38d529fb650c35524 (diff) |
sched: Add new wakeup preemption mode: WAKEUP_RUNNING
Create a new wakeup preemption mode, preempt towards tasks that run
shorter on avg. It sets next buddy to be sure we actually run the task
we preempted for.
Test results:
root@twins:~# while :; do :; done &
[1] 6537
root@twins:~# while :; do :; done &
[2] 6538
root@twins:~# while :; do :; done &
[3] 6539
root@twins:~# while :; do :; done &
[4] 6540
root@twins:/home/peter# ./latt -c4 sleep 4
Entries: 48 (clients=4)
Averages:
------------------------------
Max 4750 usec
Avg 497 usec
Stdev 737 usec
root@twins:/home/peter# echo WAKEUP_RUNNING > /debug/sched_features
root@twins:/home/peter# ./latt -c4 sleep 4
Entries: 48 (clients=4)
Averages:
------------------------------
Max 14 usec
Avg 5 usec
Stdev 3 usec
Disabled by default - needs more testing.
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Acked-by: Mike Galbraith <efault@gmx.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
LKML-Reference: <new-submission>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/sched.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index b4a39bb2b4a4..8af3d249170e 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -1113,6 +1113,8 @@ struct sched_entity { | |||
1113 | u64 start_runtime; | 1113 | u64 start_runtime; |
1114 | u64 avg_wakeup; | 1114 | u64 avg_wakeup; |
1115 | 1115 | ||
1116 | u64 avg_running; | ||
1117 | |||
1116 | #ifdef CONFIG_SCHEDSTATS | 1118 | #ifdef CONFIG_SCHEDSTATS |
1117 | u64 wait_start; | 1119 | u64 wait_start; |
1118 | u64 wait_max; | 1120 | u64 wait_max; |