From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Ian Rogers <irogers@google.com>
Cc: Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
Namhyung Kim <namhyung@kernel.org>,
Mark Rutland <mark.rutland@arm.com>,
Alexander Shishkin <alexander.shishkin@linux.intel.com>,
Jiri Olsa <jolsa@kernel.org>,
Adrian Hunter <adrian.hunter@intel.com>,
Kan Liang <kan.liang@linux.intel.com>,
"Masami Hiramatsu (Google)" <mhiramat@kernel.org>,
James Clark <james.clark@linaro.org>,
Weilin Wang <weilin.wang@intel.com>,
Dominique Martinet <asmadeus@codewreck.org>,
Thomas Richter <tmricht@linux.ibm.com>,
Junhao He <hejunhao3@huawei.com>,
Jean-Philippe Romain <jean-philippe.romain@foss.st.com>,
linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org,
Brendan Gregg <brendan@intel.com>,
gabriel.munoz@intel.com, matthew.olson@intel.com,
brandon.kammerdiener@intel.com, dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v3 0/4] Add support for a DRM tool like PMU
Date: Wed, 30 Apr 2025 20:36:29 -0300 [thread overview]
Message-ID: <aBKz_Tg-s20Qsv6k@x1> (raw)
In-Reply-To: <CAP-5=fXkayZ7pj+EctOtSBiTcGuyi6SHm9c5RZ3HyyPYcot9zA@mail.gmail.com>
On Wed, Apr 30, 2025 at 08:21:59AM -0700, Ian Rogers wrote:
> On Thu, Apr 3, 2025 at 1:24 PM Ian Rogers <irogers@google.com> wrote:
> >
> > DRM clients expose information through usage stats as documented in
> > Documentation/gpu/drm-usage-stats.rst (available online at
> > https://docs.kernel.org/gpu/drm-usage-stats.html). Add a tool like
> > PMU, similar to the hwmon PMU, that exposes DRM information.
Looks useful, I'll try to review and test tomorrow, but most probably
Friday, as tomorrow is labour day in this part of the world.
- Arnaldo
> I'm reminded by Brendan Gregg's new blog:
> https://www.brendangregg.com/blog/2025-05-01/doom-gpu-flame-graphs.html
> that this is still outstanding. The patches also reduce some directory
> scanning for the hwmon "PMU", they are in Google's tree:
> https://github.com/googleprodkernel/linux-perf/blob/google_tools_master/tools/perf/util/drm_pmu.c
>
> Thanks,
> Ian
>
> > v3: Minor tweak to the test so the skip (exit 2) doesn't trigger the
> > trap cleanup.
> >
> > v2: Add support to only scan hwmon and drm PMUs if the event or PMU
> > wildcard can match. Add a test as requested by Namhyung. Add file
> > comments.
> >
> > v1:
> > https://lore.kernel.org/lkml/20250211071727.364389-1-irogers@google.com/
> >
> > Ian Rogers (4):
> > perf parse-events: Avoid scanning PMUs that can't contain events
> > perf parse-events: Avoid scanning PMUs that can't match a wildcard
> > perf drm_pmu: Add a tool like PMU to expose DRM information
> > perf tests: Add a DRM PMU test
> >
> > tools/perf/tests/shell/drm_pmu.sh | 78 ++++
> > tools/perf/util/Build | 1 +
> > tools/perf/util/drm_pmu.c | 689 ++++++++++++++++++++++++++++++
> > tools/perf/util/drm_pmu.h | 39 ++
> > tools/perf/util/evsel.c | 9 +
> > tools/perf/util/parse-events.c | 30 +-
> > tools/perf/util/pmu.c | 15 +
> > tools/perf/util/pmu.h | 4 +-
> > tools/perf/util/pmus.c | 101 ++++-
> > tools/perf/util/pmus.h | 2 +
> > 10 files changed, 952 insertions(+), 16 deletions(-)
> > create mode 100755 tools/perf/tests/shell/drm_pmu.sh
> > create mode 100644 tools/perf/util/drm_pmu.c
> > create mode 100644 tools/perf/util/drm_pmu.h
> >
> > --
> > 2.49.0.504.g3bcea36a83-goog
> >
next prev parent reply other threads:[~2025-04-30 23:36 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-03 20:24 [PATCH v3 0/4] Add support for a DRM tool like PMU Ian Rogers
2025-04-03 20:24 ` [PATCH v3 1/4] perf parse-events: Avoid scanning PMUs that can't contain events Ian Rogers
2025-04-03 20:24 ` [PATCH v3 2/4] perf parse-events: Avoid scanning PMUs that can't match a wildcard Ian Rogers
2025-04-03 20:24 ` [PATCH v3 3/4] perf drm_pmu: Add a tool like PMU to expose DRM information Ian Rogers
2025-04-03 20:24 ` [PATCH v3 4/4] perf tests: Add a DRM PMU test Ian Rogers
2025-04-30 15:21 ` [PATCH v3 0/4] Add support for a DRM tool like PMU Ian Rogers
2025-04-30 23:36 ` Arnaldo Carvalho de Melo [this message]
2025-05-27 21:08 ` Ian Rogers
2025-06-23 23:22 ` Namhyung Kim
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aBKz_Tg-s20Qsv6k@x1 \
--to=acme@kernel.org \
--cc=adrian.hunter@intel.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=asmadeus@codewreck.org \
--cc=brandon.kammerdiener@intel.com \
--cc=brendan@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=gabriel.munoz@intel.com \
--cc=hejunhao3@huawei.com \
--cc=irogers@google.com \
--cc=james.clark@linaro.org \
--cc=jean-philippe.romain@foss.st.com \
--cc=jolsa@kernel.org \
--cc=kan.liang@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=matthew.olson@intel.com \
--cc=mhiramat@kernel.org \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
--cc=tmricht@linux.ibm.com \
--cc=weilin.wang@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox