Re: [PATCH v7 00/27] Legacy hardware/cache events as json
From: James Clark
Date: Wed Oct 15 2025 - 13:39:07 EST
On 15/10/2025 4:53 pm, Namhyung Kim wrote:
On Sun, 05 Oct 2025 11:24:03 -0700, Ian Rogers wrote:
Mirroring similar work for software events in commit 6e9fa4131abb
("perf parse-events: Remove non-json software events"). These changes
migrate the legacy hardware and cache events to json. With no hard
coded legacy hardware or cache events the wild card, case
insensitivity, etc. is consistent for events. This does, however, mean
events like cycles will wild card against all PMUs. A change doing the
same was originally posted and merged from:
https://lore.kernel.org/r/20240416061533.921723-10-irogers@xxxxxxxxxx
and reverted by Linus in commit 4f1b067359ac ("Revert "perf
parse-events: Prefer sysfs/JSON hardware events over legacy"") due to
his dislike for the cycles behavior on ARM with perf record. Earlier
patches in this series make perf record event opening failures
non-fatal and hide the cycles event's failure to open on ARM in perf
record, so it is expected the behavior will now be transparent in perf
record on ARM. perf stat with a cycles event will wildcard open the
event on all PMUs, however, with default events the cycles event will
only be opened on core PMUs.
[...]
Applied to perf-tools-next, thanks!
Best regards,
Namhyung
Hi Namhyung,
I'm still getting the build failure that I mentioned on patch 5. This only seems to happen with out of source builds:
$ make -C tools/perf O=../build/local/ V=1
static const struct pmu_sys_events pmu_sys_event_tables[] = {
{
- .event_table = {
- .pmus = pmu_events__test_soc_sys,
- .num_pmus = ARRAY_SIZE(pmu_events__test_soc_sys)
- },
- .name = "pmu_events__test_soc_sys",
- },
- {
.event_table = { 0, 0 },
.metric_table = { 0, 0 },
},
make[3]: *** [pmu-events/Build:54: /home/james/workspace/linux/build/local/pmu-events/empty-pmu-events.log] Error 1
Thanks
James