Skip to content

Commit

Permalink
perf list: Filter metrics too
Browse files Browse the repository at this point in the history
When a filter is specified on the command line, filter the metrics too.

Before:

  % perf list foo
  List of pre-defined events (to be used in -e):

  Metric Groups:

  DSB:
    DSB_Coverage
         [Fraction of Uops delivered by the DSB (aka Decoded Icache; or Uop Cache)]
  ... more metrics ...

After:

% perf list foo

  List of pre-defined events (to be used in -e):

  Metric Groups:

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Acked-by: Jiri Olsa <jolsa@kernel.org>
LPU-Reference: 20190314225002.30108-1-andi@firstfloor.org
Link: https://lkml.kernel.org/n/tip-1y8oi2s8c4jhjtykgs5zvda1@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
  • Loading branch information
Andi Kleen authored and Arnaldo Carvalho de Melo committed Mar 19, 2019
1 parent dfcbc2f commit 6f40b2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/perf/builtin-list.c
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ int cmd_list(int argc, const char **argv)
details_flag);
print_tracepoint_events(NULL, s, raw_dump);
print_sdt_events(NULL, s, raw_dump);
metricgroup__print(true, true, NULL, raw_dump, details_flag);
metricgroup__print(true, true, s, raw_dump, details_flag);
free(s);
}
}
Expand Down

0 comments on commit 6f40b2a

Please sign in to comment.