]> git.baikalelectronics.ru Git - kernel.git/commit
sched: tidy up and simplify the bonus balance
authorIngo Molnar <mingo@elte.hu>
Fri, 24 Aug 2007 18:39:10 +0000 (20:39 +0200)
committerIngo Molnar <mingo@elte.hu>
Fri, 24 Aug 2007 18:39:10 +0000 (20:39 +0200)
commitaa31795cf94c66bbb4967ec5cdc846188986d045
tree9075055664141cc1b91a0b3eac915e6241e38801
parenta70b38b8a7a93c7ddb11a6b08f9fe8c5a37db887
sched: tidy up and simplify the bonus balance

make the bonus balance more consistent: do not hand out a bonus if
there's too much in flight already, and only deduct as much from a
runner as it has the capacity. This makes the bonus engine a zero-sum
game (as intended).

this also simplifies the code:

   text    data     bss     dec     hex filename
  34770    2998      24   37792    93a0 sched.o.before
  34749    2998      24   37771    938b sched.o.after

and it also avoids overscheduling in sleep-happy workloads like
hackbench.c.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/sched_fair.c