[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20191211224800.9066-1-jolsa@kernel.org>
Date: Wed, 11 Dec 2019 23:47:57 +0100
From: Jiri Olsa <jolsa@...nel.org>
To: Arnaldo Carvalho de Melo <acme@...nel.org>
Cc: lkml <linux-kernel@...r.kernel.org>,
Ingo Molnar <mingo@...nel.org>,
Namhyung Kim <namhyung@...nel.org>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Peter Zijlstra <a.p.zijlstra@...llo.nl>,
Michael Petlan <mpetlan@...hat.com>,
Joe Mario <jmario@...hat.com>, Andi Kleen <ak@...ux.intel.com>,
Kajol Jain <kjain@...ux.ibm.com>
Subject: [RFC 0/3] perf tools: Add support for used defined metric
hi,
Joe asked for possibility to add user defined metrics. Given that
we already have metrics support, I added --metric option that allows
to specify metric on the command line, like:
# perf stat --metric 'DECODED_ICACHE_UOPS% = 100 * (idq.dsb_uops / \
(idq.ms_uops + idq.mite_uops + idq.dsb_uops + lsd.uops))' ...
The code facilitates the current metric code, and I was surprised
how easy it was, so I'm not sure I omitted something ;-)
Also available in:
git://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
perf/metric
thoughts?
jirka
---
Jiri Olsa (3):
perf tools: Factor metric addition into add_metric function
perf tools: Factor metric setup code into metricgroup__setup function
perf stat: Add --metric option
tools/perf/Documentation/perf-stat.txt | 16 ++++++++++
tools/perf/builtin-stat.c | 21 +++++++++++++
tools/perf/util/metricgroup.c | 189 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++------------------------------------
tools/perf/util/metricgroup.h | 2 ++
4 files changed, 168 insertions(+), 60 deletions(-)
Powered by blists - more mailing lists