]> www.infradead.org Git - users/jedix/linux-maple.git/commit
perf stat: Changes to event name uniquification
authorIan Rogers <irogers@google.com>
Sat, 1 Feb 2025 07:43:20 +0000 (23:43 -0800)
committerNamhyung Kim <namhyung@kernel.org>
Wed, 5 Feb 2025 05:29:13 +0000 (21:29 -0800)
commit357b965deba9fb71467413e473764ec4e1694d8d
tree620daea2eb346e37ee3030721fe1bd59d577a5b8
parent2d9961c690d299893735783a2077e866f2d46a56
perf stat: Changes to event name uniquification

The existing logic would disable uniquification on an evlist or enable
it per evsel, this is unfortunate as uniquification is most needed
when events have the same name and so the whole evlist must be
considered.  Change the initial disable uniquify on an evlist
processing to also set a needs_uniquify flag, for cases like the
matching event names. This must be done as an initial pass as
uniquification of an event name will change the behavior of the
check. Keep the per counter uniquification but now only uniquify event
names when the needs_uniquify flag is set.

Before this change a hwmon like temp1 wouldn't be uniquified and
afterwards it will (ie the PMU is added to the temp1 event's name).

Signed-off-by: Ian Rogers <irogers@google.com>
Reviewed-by: Kan Liang <kan.liang@linux.intel.com>
Link: https://lore.kernel.org/r/20250201074320.746259-6-irogers@google.com
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
tools/perf/util/evsel.h
tools/perf/util/stat-display.c