Skip to content

perf stat: Add --per-node option

Jiri Olsa lkml 2 versions – Applied

Status from this message: Thanks, applied.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 2 repliesApplied
  2. v13 patches 6 repliesApplied

Changes in v2 from the cover letter

- use mallox instead of zalloc plus adding comment [Arnaldo]
- rename --per-numa to --per-node [Alexey]
- rename function names to have node instead of numa

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/3libperf: Add perf_cpu_map__max functiontools/perf/builtin-stat.c tools/perf/lib/cpumap.c tools/perf/lib/include/perf/cpumap.h +1 more+15 -130 replies
2/3perf tools: Add perf_env__numa_node functiontools/perf/util/env.c tools/perf/util/env.h+46 -00 replies
3/3perf stat: Add --per-node agregation supporttools/perf/Documentation/perf-stat.txt tools/perf/builtin-stat.c tools/perf/util/cpumap.c +4 more+95 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCHv2 0/3] perf stat: Add --per-node option

hi,
adding --per-node option to aggregate stats per NUMA nodes, you can get now use stat command like:

  # perf stat  -a -I 1000 -e cycles --per-node
  #           time node   cpus             counts unit events
       1.000542550 N0       20          6,202,097      cycles
       1.000542550 N1       20            639,559      cycles
       2.002040063 N0       20          7,412,495      cycles
       2.002040063 N1       20          2,185,577      cycles
       3.003451699 N0       20          6,508,917      cycles
       3.003451699 N1       20            765,607      cycles
  ...

v2 changes:
- use mallox instead of zalloc plus adding comment [Arnaldo]
- rename --per-numa to --per-node [Alexey]
- rename function names to have node instead of numa

Available also in:
git://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
perf/fixes

thanks,
jirka

---
Jiri Olsa (3):
libperf: Add perf_cpu_map__max function perf tools: Add perf_env__numa_node function perf stat: Add --per-node agregation support

 tools/perf/Documentation/perf-stat.txt |  5 +++++
 tools/perf/builtin-stat.c              | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++----------
 tools/perf/lib/cpumap.c                | 12 ++++++++++++
 tools/perf/lib/include/perf/cpumap.h   |  1 +
 tools/perf/lib/libperf.map             |  1 +
 tools/perf/util/cpumap.c               | 18 ++++++++++++++++++
 tools/perf/util/cpumap.h               |  3 +++
 tools/perf/util/env.c                  | 40 ++++++++++++++++++++++++++++++++++++++++
 tools/perf/util/env.h                  |  6 ++++++
 tools/perf/util/stat-display.c         | 15 +++++++++++++++
 tools/perf/util/stat.c                 |  1 +
 tools/perf/util/stat.h                 |  1 +
 12 files changed, 153 insertions(+), 10 deletions(-)