lkml.org 
[lkml]   [2010]   [Nov]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 1/2] perf-events: Add support for supplementary event registers v2
From
Date
On Fri, 2010-11-12 at 18:17 +0100, Stephane Eranian wrote:
> I looked at this patch thinking how could this be reused for LBR_SELECT.
>
> I am wondering if storing the extra MSR value in attr.config is really the way
> to go now as opposed to adding/overloading a field.
>
> For OFFCORE_RESPONSE, it makes sense to use attr.config because this is
> a refinement of the event (a sub-sub event if you want).

Correct, it makes sense for offcore and load-latency, not so much for
lbr_config.

> For LBR_SELECT, you also need to pass a value, but there is no specific event
> associated with it. You can enable LBR with any event you want. Thus,
> storing the
> LBR_SELECT value independently would also make sense. And if we have this
> field for LBR_SELECT then we may as well use it for OFFCORE_REPONSE.

That would assume a single event doesn't contain offcore and lbr, no?
Currently the extra_reg thing assumes there's only one extra reg encoded
in the config word.

> The alternative would be to consider LBR_SELECT also as a refinement of
> the event being measured. Though by itself, it wouldn't do anything, it would
> have to be combine with a PERF_SAMPLE_BRANCH_STACK to attr.sample_type.

A separate field for the lbr_config seems to make most sense, we could
of course use the top 16 bits for lbr, the next 16 for offcore/ll and
the bottom 32 for eventsel, but that's mighty crowded.




\
 
 \ /
  Last update: 2010-11-12 18:35    [W:0.666 / U:0.000 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site