lkml.org 
[lkml]   [2008]   [Nov]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: busted CFS group load balancer?
From
On Tue, Nov 18, 2008 at 4:30 AM, Peter Zijlstra <a.p.zijlstra@chello.nl> wrote:
>> I'm also very troubled with this calculation in __update_group_shares_cpu():
>>
>> shares = (sd_shares * rq_weight) / (sd_rq_weight + 1);
>>
>> Won't you have rounding problem here? value 'shares' will gradually
>> decrease for each iteration of __update_group_shares_cpu()?
>
> Yes it will, however at the top of the sched-domain tree its reset.
>
> if (!sd->parent || !(sd->parent->flags & SD_LOAD_BALANCE))
> shares = tg->shares;

Hmm? it is only true mostly on flat smp machine, or on numa system
where task is woken up across a sched-domain.

There is this code in try_to_wake_up():

for_each_domain(this_cpu, sd) {
if (cpu_isset(cpu, sd->span)) {
update_shares(sd);
break;
}
}

It doesn't iterate to the top half of the time on numa machine.

- Ken


\
 
 \ /
  Last update: 2008-11-18 18:29    [W:0.408 / U:0.032 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site