From: Peter Zijlstra <peterz@infradead.org>
To: eranian@gmail.com
Cc: Ingo Molnar <mingo@kernel.org>,
Linus Torvalds <torvalds@linux-foundation.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Arnaldo Carvalho de Melo <acme@infradead.org>,
Thomas Gleixner <tglx@linutronix.de>,
Andi Kleen <andi@firstfloor.org>
Subject: Re: PEBS bug on HSW: "Unexpected number of pebs records 10" (was: Re: [GIT PULL] perf changes for v3.12)
Date: Mon, 23 Sep 2013 19:24:58 +0200 [thread overview]
Message-ID: <20130923172458.GE9326@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <CAMsRxfJxbnoFFkwCc3geOb579UpSaVxLc-Cp7mQES250daci-A@mail.gmail.com>
On Mon, Sep 23, 2013 at 07:11:21PM +0200, Stephane Eranian wrote:
> Ok so what you are saying is that the ovfl_status is not maintained private
> to each counter but shared among all PEBS counters by ucode. That's
> how you end up leaking between counters like that.
I only remember asking for clarification because the SDM isn't clear on
this subject; the answer was that it simply copies whatever is in
MSR_CORE_PERF_GLOBAL_STATUS.
I explained how this would be a problem and it was agreed this needed
fixing -- not sure if that ever happened.
> But the other thing I remember is that if two PEBS events overflow
> at the same time, PEBS only write one record with 2 bits set in the
> ovfl_status field. No point in creating two because the machine state
> will be the same for both. The kernel would just need to dispatch the
> same PEBS record to all the events that overflowed.
Hurm.. that makes life more interesting still. The current code only
delivers the event to the first bit set. Changing this would be simple
though.
> Now, your case appears like that, except this is not what happened.
> So you're misled to believe both counter overflowed at the same time
> when they did not in reality.
>
> I'd like to have a test case where I could reproduce this.
Agreed, I've never tried to actually reproduce this. I suppose it would
be easiest to trigger where the one event is very rare and controlled.
next prev parent reply other threads:[~2013-09-23 17:25 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-03 13:29 [GIT PULL] perf changes for v3.12 Ingo Molnar
2013-09-03 13:37 ` Arnaldo Carvalho de Melo
2013-09-03 13:43 ` Ingo Molnar
2013-09-03 17:02 ` Vince Weaver
2013-09-04 17:53 ` Linus Torvalds
2013-09-05 10:56 ` Ingo Molnar
2013-09-05 12:42 ` Frederic Weisbecker
2013-09-05 12:51 ` Ingo Molnar
2013-09-05 12:58 ` Frederic Weisbecker
2013-09-10 8:06 ` Namhyung Kim
2013-09-10 11:18 ` Frederic Weisbecker
2013-09-05 13:38 ` Ingo Molnar
2013-09-08 2:17 ` Linus Torvalds
2013-09-09 10:05 ` Peter Zijlstra
2013-09-10 11:28 ` Stephane Eranian
2013-09-10 11:53 ` PEBS bug on HSW: "Unexpected number of pebs records 10" (was: Re: [GIT PULL] perf changes for v3.12) Ingo Molnar
2013-09-10 12:32 ` Stephane Eranian
2013-09-10 12:42 ` Ramkumar Ramachandra
2013-09-10 12:51 ` Ramkumar Ramachandra
2013-09-10 12:55 ` Stephane Eranian
2013-09-10 13:22 ` Ingo Molnar
2013-09-10 13:38 ` Ingo Molnar
2013-09-10 14:15 ` Stephane Eranian
2013-09-10 14:29 ` Ingo Molnar
2013-09-10 14:34 ` Stephane Eranian
2013-09-10 17:14 ` Ingo Molnar
2013-09-16 11:07 ` Stephane Eranian
2013-09-16 15:41 ` Ingo Molnar
2013-09-16 16:29 ` Peter Zijlstra
2013-09-17 7:00 ` Ingo Molnar
2013-09-23 15:25 ` Stephane Eranian
2013-09-23 15:33 ` Peter Zijlstra
2013-09-23 17:11 ` Stephane Eranian
2013-09-23 17:24 ` Peter Zijlstra [this message]
2013-09-10 15:28 ` Peter Zijlstra
2013-09-10 16:14 ` Stephane Eranian
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=20130923172458.GE9326@twins.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=acme@infradead.org \
--cc=andi@firstfloor.org \
--cc=eranian@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.org \
/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