From: Peter Zijlstra <peterz@infradead.org>
To: John Stultz <john.stultz@linaro.org>
Cc: Pawel Moll <pawel.moll@arm.com>,
Steven Rostedt <rostedt@goodmis.org>,
Ingo Molnar <mingo@redhat.com>, Oleg Nesterov <oleg@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>,
Mel Gorman <mgorman@suse.de>,
Andy Lutomirski <luto@amacapital.net>,
Stephen Boyd <sboyd@codeaurora.org>,
Baruch Siach <baruch@tkos.co.il>,
Thomas Gleixner <tglx@linutronix.de>,
lkml <linux-kernel@vger.kernel.org>
Subject: Re: [RFC] sched_clock: Track monotonic raw clock
Date: Fri, 18 Jul 2014 22:22:50 +0200 [thread overview]
Message-ID: <20140718202250.GR9918@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <53C97995.2090500@linaro.org>
[-- Attachment #1: Type: text/plain, Size: 1652 bytes --]
On Fri, Jul 18, 2014 at 12:46:29PM -0700, John Stultz wrote:
> On 07/18/2014 12:34 PM, Peter Zijlstra wrote:
> > On Fri, Jul 18, 2014 at 12:25:48PM -0700, John Stultz wrote:
> >> Also, assuming we someday will merge the x86 sched_clock logic into
> >> the generic sched_clock code, we'll have to handle cases where they
> >> aren't the same.
> > I prefer that to not happen. I spend quite a bit of time and effort to
> > make the x86 code go fast, and that generic code doesn't look like fast
> > at all.
>
> A stretch goal then :)
>
> But yes, the generic sched_clock logic has really just started w/ ARM
> and is hopefully moving out to pick up more architectures. I suspect it
> will need to adapt many of your tricks from (if not a whole migration to
> some of) the x86 code. And even if the x86 code stays separate for
> optimization reasons, thats fine.
So the generic stuff seems optimized for 32bit arch, short clocks and
seems to hard assume the clock is globally consistent.
The x86 sched_clock code is optimized for 64bit, has a full 64bit clock
and cannot ever assume the thing is globally consistent (until Intel/AMD
stop making the TSC register writable -- including, and maybe
especially, for SMM).
There is just not much that overlaps there.
> But as folks try to align things like perf timestamps with time domains
> we expose to userspace, we'll have to keep some of the semantics in sync
> between the various implementations, and having lots of separate
> implementations will be a burden.
We're already there, there's about nr_arch - 5 implementations,
hopefully many trivial ones though.
[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2014-07-18 20:23 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-18 17:43 [RFC] sched_clock: Track monotonic raw clock Pawel Moll
2014-07-18 17:51 ` John Stultz
2014-07-18 19:06 ` Peter Zijlstra
2014-07-22 16:17 ` Pawel Moll
2014-07-18 19:13 ` Peter Zijlstra
2014-07-18 19:25 ` John Stultz
2014-07-18 19:34 ` Peter Zijlstra
2014-07-18 19:46 ` John Stultz
2014-07-18 20:22 ` Peter Zijlstra [this message]
2014-07-18 22:41 ` Peter Zijlstra
2014-07-22 16:17 ` Pawel Moll
2014-07-22 16:29 ` Peter Zijlstra
2014-07-22 16:17 ` Pawel Moll
2014-07-19 5:02 ` Richard Cochran
2014-07-22 16:17 ` Pawel Moll
2014-07-22 16:34 ` Peter Zijlstra
2014-07-22 16:48 ` Pawel Moll
2014-07-22 19:39 ` Richard Cochran
2014-09-12 11:45 ` Pawel Moll
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=20140718202250.GR9918@twins.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=akpm@linux-foundation.org \
--cc=baruch@tkos.co.il \
--cc=john.stultz@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luto@amacapital.net \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=oleg@redhat.com \
--cc=pawel.moll@arm.com \
--cc=rostedt@goodmis.org \
--cc=sboyd@codeaurora.org \
--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