lkml.org 
[lkml]   [2023]   [Mar]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v1 05/10] perf evsel: Limit in group test to CPUs
Em Wed, Mar 01, 2023 at 08:12:06PM -0800, Ian Rogers escreveu:
> Don't just match on the event name, restict based on the PMU too.

restrict.

Can you please expand a bit this explanation?

- Arnaldo

> Signed-off-by: Ian Rogers <irogers@google.com>
> ---
> tools/perf/arch/x86/util/evsel.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/tools/perf/arch/x86/util/evsel.c b/tools/perf/arch/x86/util/evsel.c
> index ea3972d785d1..580b0a172136 100644
> --- a/tools/perf/arch/x86/util/evsel.c
> +++ b/tools/perf/arch/x86/util/evsel.c
> @@ -61,6 +61,9 @@ bool arch_evsel__must_be_in_group(const struct evsel *evsel)
> if (!evsel__sys_has_perf_metrics(evsel))
> return false;
>
> + if (evsel->pmu_name && strncmp(evsel->pmu_name, "cpu", 3))
> + return false;
> +
> return evsel->name &&
> (strcasestr(evsel->name, "slots") ||
> strcasestr(evsel->name, "topdown"));
> --
> 2.39.2.722.g9855ee24e9-goog
>

--

- Arnaldo

\
 
 \ /
  Last update: 2023-03-27 00:42    [W:0.357 / U:0.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site