lkml.org 
[lkml]   [2018]   [Sep]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH V3 5/6] x86/intel_rdt: Use perf infrastructure for measurements
From
Date
Hi Peter,

On 9/17/2018 1:58 AM, Peter Zijlstra wrote:
> On Tue, Sep 11, 2018 at 10:14:36AM -0700, Reinette Chatre wrote:
>> +static int measure_l2_residency(void *_plr)
>> +{
>
>> + measure_residency_fn(&perf_miss_attr, &perf_hit_attr, plr, &counts);
>
>> +}
>> +
>> +static int measure_l3_residency(void *_plr)
>> +{
>
>> + measure_residency_fn(&perf_miss_attr, &perf_hit_attr, plr, &counts);
>
> Not sure it's important, but both sites loose the error return.
>

measure_l2_residency() as well as measure_l3_residency() are thread
functions so this error does not propagate directly to the caller.

Even so, by not exiting the thread here if measure_residency_fn() fails
the tracepoints will be written with zeroes. If we exited here the
tracepoints will not be written and the trace buffer will be empty when
the user searches for the measurement data. Do you perhaps have an
inclination to which a user would prefer?

Reinette

\
 
 \ /
  Last update: 2018-09-17 18:54    [W:0.071 / U:4.420 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site