From: Chase Douglas <chase.douglas@canonical.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: linux-kernel@vger.kernel.org, Ingo Molnar <mingo@elte.hu>,
Thomas Gleixner <tglx@linutronix.de>,
Andrew Morton <akpm@linux-foundation.org>,
"Rafael J. Wysocki" <rjw@sisk.pl>
Subject: Re: [REGRESSION 2.6.30][PATCH 1/1] sched: defer idle accounting till after load update period
Date: Mon, 29 Mar 2010 13:20:50 -0400 [thread overview]
Message-ID: <40ec3ea41003291020v24dd234el1300291e6bb54d9d@mail.gmail.com> (raw)
In-Reply-To: <1269873718.12097.342.camel@laptop>
On Mon, Mar 29, 2010 at 10:41 AM, Peter Zijlstra <peterz@infradead.org> wrote:
> On Mon, 2010-03-29 at 09:41 -0400, Chase Douglas wrote:
>> There's a period of 10 ticks where calc_load_tasks is updated by all the
>> cpus for the load avg. Usually all the cpus do this during the first
>> tick. If any cpus go idle, calc_load_tasks is decremented accordingly.
>> However, if they wake up calc_load_tasks is not incremented. Thus, if
>> cpus go idle during the 10 tick period, calc_load_tasks may be
>> decremented to a non-representative value. This issue can lead to
>> systems having a load avg of exactly 0, even though the real load avg
>> could theoretically be up to NR_CPUS.
>>
>> This change defers calc_load_tasks accounting after each cpu updates the
>> count until after the 10 tick period.
>
> >From reading the above changelog it seems to me there should be a
> callback from leaving nohz mode, your proposed patch has no such thing.
I believe what you're implying is that there should be a corresponding
call for when a cpu is awakened to counter the accounting when a cpu
goes to sleep during the 10 tick window. I don't think this is the
correct approach because the load avg should be a snapshot in time. If
there were 10 runnable tasks at the beginning of the load calculation
window, then we should account for 10 tasks. If they all get serviced
and the cpu goes to sleep, then wakes back up with one runnable task,
we would account for only one task instead of the original 10. What if
9 more tasks then get added to the cpu's rq during the 10 tick update
period? None of them would be accounted for either.
-- Chase
next prev parent reply other threads:[~2010-03-29 17:20 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-29 13:41 [REGRESSION 2.6.30][PATCH 0/1] " Chase Douglas
2010-03-29 13:41 ` [REGRESSION 2.6.30][PATCH 1/1] " Chase Douglas
2010-03-29 14:41 ` Peter Zijlstra
2010-03-29 17:20 ` Chase Douglas [this message]
2010-04-01 19:27 ` Andrew Morton
2010-04-01 19:37 ` Thomas Gleixner
2010-04-01 20:00 ` Chase Douglas
2010-04-01 20:18 ` Thomas Gleixner
2010-04-01 20:32 ` Chase Douglas
2010-04-01 20:37 ` Thomas Gleixner
2010-04-02 7:59 ` Peter Zijlstra
2010-04-05 14:44 ` Chase Douglas
2010-04-01 19:56 ` Chase Douglas
2010-04-01 20:01 ` Thomas Gleixner
2010-04-13 20:39 ` Andrew Morton
2010-04-13 21:02 ` Thomas Gleixner
2010-04-13 21:06 ` Chase Douglas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=40ec3ea41003291020v24dd234el1300291e6bb54d9d@mail.gmail.com \
--to=chase.douglas@canonical.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
--cc=rjw@sisk.pl \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®