From: Yuyang Du <yuyang.du@intel.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: bsegall@google.com, mingo@redhat.com,
linux-kernel@vger.kernel.org, rafael.j.wysocki@intel.com,
arjan.van.de.ven@intel.com, len.brown@intel.com,
alan.cox@intel.com, mark.gross@intel.com, pjt@google.com,
fengguang.wu@intel.com
Subject: Re: [PATCH 2/2] sched: Rewrite per entity runnable load average tracking
Date: Thu, 10 Jul 2014 07:30:49 +0800 [thread overview]
Message-ID: <20140709233049.GA12024@intel.com> (raw)
In-Reply-To: <20140709184543.GI9918@twins.programming.kicks-ass.net>
Thanks, Peter.
On Wed, Jul 09, 2014 at 08:45:43PM +0200, Peter Zijlstra wrote:
> Nope :-).. we got rid of that lock for a good reason.
>
> Also, this is one area where I feel performance really trumps
> correctness, we can fudge the blocked load a little. So the
> sched_clock_cpu() difference is a strict upper bound on the
> rq_clock_task() difference (and under 'normal' circumstances shouldn't
> be much off).
Strictly, migrating wakee task on remote CPU entails two steps:
(1) Catch up with task's queue's last_update_time, and then substract
(2) Cache up with "current" time of remote CPU (for comparable matter), and then
on new CPU, change to the new timing source (when enqueue)
So I will try sched_clock_cpu(remote_cpu) for step (2). For step (2), maybe we
should not use cfs_rq_clock_task anyway, since the task is about to going
to another CPU/queue. Is this right?
I made another mistake. Should not only track task entity load, group entity
(as an entity) is also needed. Otherwise, task_h_load can't be done correctly...
Sorry for the messup. But this won't make much change in the codes.
Thanks,
Yuyang
> So we could simply use a timestamps from dequeue and one from enqueue,
> and use that.
>
> As to the remote subtraction, a RMW on another cacheline than the
> rq->lock one should be good; esp since we don't actually observe the
> per-rq total often (once per tick or so) I think, no?
>
> The thing is, we do not want to disturb scheduling on whatever cpu the
> task last ran on if we wake it to another cpu. Taking rq->lock wrecks
> that for sure.
next prev parent reply other threads:[~2014-07-10 7:33 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-02 2:30 [PATCH 1/2] sched: Remove update_rq_runnable_avg Yuyang Du
2014-07-02 2:30 ` [PATCH 2/2] sched: Rewrite per entity runnable load average tracking Yuyang Du
2014-07-07 10:07 ` Peter Zijlstra
2014-07-07 10:46 ` Peter Zijlstra
2014-07-07 20:03 ` Yuyang Du
2014-07-07 22:25 ` bsegall
2014-07-08 0:08 ` Yuyang Du
2014-07-08 17:04 ` bsegall
2014-07-09 1:07 ` Yuyang Du
2014-07-09 17:08 ` bsegall
2014-07-09 18:39 ` Yuyang Du
2014-07-09 18:45 ` Peter Zijlstra
2014-07-09 19:07 ` bsegall
2014-07-10 10:08 ` Peter Zijlstra
2014-07-10 17:01 ` bsegall
2014-07-10 19:53 ` Yuyang Du
2014-07-10 23:22 ` Yuyang Du
2014-07-11 8:47 ` Peter Zijlstra
2014-07-11 0:52 ` Yuyang Du
2014-07-11 2:01 ` Yuyang Du
2014-07-09 23:30 ` Yuyang Du [this message]
2014-07-10 17:06 ` bsegall
2014-07-10 20:08 ` Yuyang Du
2014-07-08 12:50 ` Peter Zijlstra
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=20140709233049.GA12024@intel.com \
--to=yuyang.du@intel.com \
--cc=alan.cox@intel.com \
--cc=arjan.van.de.ven@intel.com \
--cc=bsegall@google.com \
--cc=fengguang.wu@intel.com \
--cc=len.brown@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.gross@intel.com \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=pjt@google.com \
--cc=rafael.j.wysocki@intel.com \
/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
Powered by JetHome