[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20240423031719.1941141-1-irogers@google.com>
Date: Mon, 22 Apr 2024 20:17:13 -0700
From: Ian Rogers <irogers@...gle.com>
To: Kan Liang <kan.liang@...ux.intel.com>, Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>, Arnaldo Carvalho de Melo <acme@...nel.org>, Namhyung Kim <namhyung@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>, Jiri Olsa <jolsa@...nel.org>,
Ian Rogers <irogers@...gle.com>, Adrian Hunter <adrian.hunter@...el.com>,
Jonathan Corbet <corbet@....net>, Bjorn Helgaas <bhelgaas@...gle.com>,
Randy Dunlap <rdunlap@...radead.org>, Jing Zhang <renyu.zj@...ux.alibaba.com>,
James Clark <james.clark@....com>, Ravi Bangoria <ravi.bangoria@....com>,
linux-kernel@...r.kernel.org, linux-perf-users@...r.kernel.org
Subject: [PATCH v2 0/6] Assume sysfs event names are always lowercase
By assuming sysfs events are lower case, the case insensitive event
parsing can probe for the existence of a file rather then loading all
events in a directory. When the event is a json event like
inst_retired.any on Intel, this reduces the number of openat calls on
a Tigerlake laptop from 325 down to 255.
v1 sent as an RFC:
https://lore.kernel.org/lkml/20240413040812.4042051-1-irogers@google.com/
v2: addresses review feedback from Kan Liang, by updating
documentation and adding tests.
Ian Rogers (6):
perf test pmu-events: Make it clearer that pmu-events tests json
events
perf Document: Capture that sysfs event names must be lower case
perf test pmu: Refactor format test and exposed test APIs
perf test pmu: Add an eagerly loaded event test
perf test pmu: Test all sysfs PMU event names are lowercase
perf pmu: Assume sysfs events are always lowercase
.../sysfs-bus-event_source-devices-events | 6 +
tools/perf/tests/pmu-events.c | 2 +-
tools/perf/tests/pmu.c | 444 +++++++++++-------
tools/perf/util/parse-events.c | 2 +-
tools/perf/util/parse-events.h | 2 +-
tools/perf/util/pmu.c | 97 ++--
tools/perf/util/pmu.h | 4 +-
tools/perf/util/pmus.c | 16 +-
tools/perf/util/pmus.h | 2 +
9 files changed, 377 insertions(+), 198 deletions(-)
--
2.44.0.769.g3c40516874-goog
Powered by blists - more mailing lists