lkml.org 
[lkml]   [2014]   [Aug]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 4/5] perf, x86: Add INST_RETIRED.ALL workarounds
From
[+perf tool maintainers]

On Thu, Aug 14, 2014 at 4:30 PM, Andi Kleen <ak@linux.intel.com> wrote:
>
> I understand all your points, but there's no alternative.
> The only other way would be to disable INST_RETIRED.ALL.
>
You cannot do that either. INST_RETIRED:ALL is important.
I assume the bug applies whether or not the event is used
with a filter.

I think we need to ensure that by looking at the perf.data file,
one can reconstruct the total number of inst_Retired:all
occurrences for the run. With a fixed period, one would do
num_samples * fixed_period. I know the Gooda tool does
that. It is used to estimate the number of events captured
vs. the number of events occurring.

So what I am saying is that on BDW, we need to have
perf force PERF_SAMPLE_PERIOD even with a fixed
period is passed. The kernel cannot simply add
PERF_SAMPLE_PERIOD to the event sample_format
because the tool would get confused by the sample
record size otherwise.

I understand this is not pretty. We'd need to have
a on the evsel just before making the syscall. That
callback would be for x86 and it would check the
CPUID to force PERF_SAMPLE_PERIOD. That's
my thinking but there may be a better way of doing
this.


\
 
 \ /
  Last update: 2014-08-14 20:01    [W:0.079 / U:0.128 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site