From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: "Liang, Kan" <kan.liang@linux.intel.com>
Cc: Ian Rogers <irogers@google.com>,
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>,
linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v1] perf script python: Improve physical mem type resolution
Date: Wed, 4 Dec 2024 18:14:42 -0300 [thread overview]
Message-ID: <Z1DGQp_ahnYFcF6J@x1> (raw)
In-Reply-To: <9fe0616a-edfa-4e51-9649-f19fb1d44821@linux.intel.com>
On Tue, Nov 19, 2024 at 03:05:41PM -0500, Liang, Kan wrote:
> On 2024-11-19 1:01 p.m., Ian Rogers wrote:
> > After:
> > ```
> > Event: mem_inst_retired.any:P
> > Memory type count percentage
> > ---------------------------------------- ---------- ----------
> > 100000000-105f7fffff : System RAM 9460 90.5
> > 841400000-8416599ff : Kernel data 45 0.4
> > 840800000-8412a6fff : Kernel rodata 19 0.2
> > 841ebe000-8423fffff : Kernel bss 12 0.1
> > 0-fff : Reserved 998 9.5
> > ```
> > The code has been updated to python 3 with type hints and resolving
> > issues reported by mypy and pylint. Tabs are swapped to spaces as
> > preferred in PEP8, because most lines of code were modified (of this
> > small file) and this makes pylint significantly less noisy.
> Thanks Ian. A very nice improvement!
> Acked-by: Kan Liang <kan.liang@linux.intel.com>
Thanks, tested on a:
root@number:/tmp# grep -m1 "model name" /proc/cpuinfo
model name : Intel(R) Core(TM) i7-14700K
root@number:/tmp#
and applied to perf-tools-next:
root@number:/tmp# perf script mem-phys-addr -a find /
<SNIP>
/bin
/lib
/lib64
/sbin
Warning:
744 out of order events recorded.
Event: cpu_core/mem_inst_retired.all_loads/P
Memory type count percentage
---------------------------------------- ---------- ----------
100000000-8bfbfffff : System RAM 364561 76.5
621400000-6223a6fff : Kernel rodata 10474 2.2
622400000-62283d4bf : Kernel data 4828 1.0
623304000-6237fffff : Kernel bss 1063 0.2
620000000-6213fffff : Kernel code 98 0.0
0-fff : Reserved 111480 23.4
100000-2b0ca017 : System RAM 337 0.1
2fbad000-30d92fff : System RAM 44 0.0
2c79d000-2fbabfff : System RAM 30 0.0
30d94000-316d5fff : System RAM 16 0.0
2b131a58-2c71dfff : System RAM 7 0.0
root@number:/tmp#
- Arnaldo
prev parent reply other threads:[~2024-12-04 21:14 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-19 18:01 [PATCH v1] perf script python: Improve physical mem type resolution Ian Rogers
2024-11-19 20:05 ` Liang, Kan
2024-12-04 21:14 ` Arnaldo Carvalho de Melo [this message]
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=Z1DGQp_ahnYFcF6J@x1 \
--to=acme@kernel.org \
--cc=adrian.hunter@intel.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=irogers@google.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=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
/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