diff options
author | Paul Turner <[email protected]> | 2012-10-04 13:18:31 +0200 |
---|---|---|
committer | Ingo Molnar <[email protected]> | 2012-10-24 10:27:26 +0200 |
commit | bb17f65571e97a7ec0297571fb1154fbd107ad00 (patch) | |
tree | d7574f5a57abe38112cbac832a29354ee1e4fa64 /lib/string_helpers.c | |
parent | 8165e145ceb62fc338e099c9b12b3239c83d2f8e (diff) |
sched: Normalize tg load contributions against runnable time
Entities of equal weight should receive equitable distribution of cpu time.
This is challenging in the case of a task_group's shares as execution may be
occurring on multiple cpus simultaneously.
To handle this we divide up the shares into weights proportionate with the load
on each cfs_rq. This does not however, account for the fact that the sum of
the parts may be less than one cpu and so we need to normalize:
load(tg) = min(runnable_avg(tg), 1) * tg->shares
Where runnable_avg is the aggregate time in which the task_group had runnable
children.
Signed-off-by: Paul Turner <[email protected]>
Reviewed-by: Ben Segall <[email protected]>.
Signed-off-by: Peter Zijlstra <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Ingo Molnar <[email protected]>
Diffstat (limited to 'lib/string_helpers.c')
0 files changed, 0 insertions, 0 deletions