perf record: Uniquify hybrid event name
authorJin Yao <yao.jin@linux.intel.com>
Tue, 27 Apr 2021 07:01:30 +0000 (15:01 +0800)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 29 Apr 2021 13:30:59 +0000 (10:30 -0300)
commit91c0f5ec812f38f5e900b5557254baf563c4a2e3
tree9ba4293deaa87df655b7d6800c069a89e12be1df
parent660e533e87ff4e66434f90fca987b929d4eb0059
perf record: Uniquify hybrid event name

For perf-record, it would be useful to tell user the pmu which the
event belongs to.

For example,

  # perf record -a -- sleep 1
  # perf report

  # To display the perf.data header info, please use --header/--header-only options.
  #
  #
  # Total Lost Samples: 0
  #
  # Samples: 106  of event 'cpu_core/cycles/'
  # Event count (approx.): 22043448
  #
  # Overhead  Command       Shared Object            Symbol
  # ........  ............  .......................  ............................
  #
  ...

Signed-off-by: Jin Yao <yao.jin@linux.intel.com>
Reviewed-by: Jiri Olsa <jolsa@kernel.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Kan Liang <kan.liang@intel.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: https://lore.kernel.org/r/20210427070139.25256-18-yao.jin@linux.intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-record.c