On Wed, May 21, 2025 at 10:28 AM Likhitha Korrapati
wrote:
>
> Hi Ian,
>
> On 5/21/25 21:15, Ian Rogers wrote:
> > On Wed, May 21, 2025 at 6:03 AM Likhitha Korrapati
> > wrote:
> >>
> >> Hi Arnaldo,
> >>
> >> On 5/14/25 02:43, Arnaldo
On Wed, May 21, 2025 at 6:03 AM Likhitha Korrapati
wrote:
>
> Hi Arnaldo,
>
> On 5/14/25 02:43, Arnaldo Carvalho de Melo wrote:
> > On Fri, May 02, 2025 at 01:14:32PM +0530, Mukesh Kumar Chaurasiya wrote:
> >> On Fri, Apr 25, 2025 at 02:46:43PM -0300, Arnaldo Carvalho de Melo wrote:
> >>> Maybe th
On Tue, May 13, 2025 at 3:12 PM Ian Rogers wrote:
>
> On Tue, May 13, 2025 at 2:13 PM Arnaldo Carvalho de Melo
> wrote:
> >
> > On Fri, May 02, 2025 at 01:14:32PM +0530, Mukesh Kumar Chaurasiya wrote:
> > > On Fri, Apr 25, 2025 at 02:46:43PM -0300, Arnaldo Carvalh
On Tue, May 13, 2025 at 2:13 PM Arnaldo Carvalho de Melo
wrote:
>
> On Fri, May 02, 2025 at 01:14:32PM +0530, Mukesh Kumar Chaurasiya wrote:
> > On Fri, Apr 25, 2025 at 02:46:43PM -0300, Arnaldo Carvalho de Melo wrote:
> > > Maybe that max() call in perf_cpu_map__intersect() somehow makes the
> >
dress of the following map.
>
> Fix it by really taking the next entry, also make sure that entry
> follows current one by making sure entries are sorted.
>
> Fixes: 659ad3492b91 ("perf maps: Switch from rbtree to lazily sorted array
> for addresses")
> Signed-off-b
On Tue, Jan 7, 2025 at 12:50 AM Christophe Leroy
wrote:
>
> Le 06/01/2025 à 21:05, Ian Rogers a écrit :
> > On Mon, Jan 6, 2025 at 11:38 AM Christophe Leroy
> > wrote:
> >>
> >> Building perf with EXTRA_CFLAGS="-DMAX_NR_CPUS=1" fails:
> >&
On Mon, Jan 6, 2025 at 11:38 AM Christophe Leroy
wrote:
>
> Since commit 659ad3492b91 ("perf maps: Switch from rbtree to lazily
> sorted array for addresses"), perf doesn't display anymore kernel
> symbols on powerpc, allthough it still detects them as kernel addresses.
>
> # Overhead Com
On Mon, Jan 6, 2025 at 11:38 AM Christophe Leroy
wrote:
>
> Building perf with EXTRA_CFLAGS="-DMAX_NR_CPUS=1" fails:
>
> CC /home/chleroy/linux-powerpc/tools/perf/libperf/cpumap.o
> cpumap.c:16: error: "MAX_NR_CPUS" redefined [-Werror]
>16 | #define MAX_NR_CPUS 4
On Wed, Dec 4, 2024 at 10:33 PM Ian Rogers wrote:
>
> On Wed, Dec 4, 2024 at 9:47 PM Namhyung Kim wrote:
> >
> > Hi Ian,
> >
> > On Wed, Dec 04, 2024 at 06:23:05PM -0800, Ian Rogers wrote:
> > > The refactoring of tool PMU events to have a PMU then adding
On Wed, Dec 4, 2024 at 9:47 PM Namhyung Kim wrote:
>
> Hi Ian,
>
> On Wed, Dec 04, 2024 at 06:23:05PM -0800, Ian Rogers wrote:
> > The refactoring of tool PMU events to have a PMU then adding the expr
> > literals to the tool PMU made it so that the literal system_tsc_fre
: 609aa2667f67 ("perf tool_pmu: Switch to standard pmu functions and json
descriptions")
Reported-by: Athira Rajeev
Closes:
https://lore.kernel.org/linux-perf-users/20241022140156.98854-1-atraj...@linux.vnet.ibm.com/
Co-developed-by: Athira Rajeev
Signed-off-by: Ian Rogers
---
tools/perf/te
On Sun, Nov 3, 2024 at 8:17 PM Athira Rajeev
wrote:
>
>
>
> > On 30 Oct 2024, at 5:29 AM, Namhyung Kim wrote:
> >
> > Hello,
> >
> > On Tue, Oct 22, 2024 at 07:31:56PM +0530, Athira Rajeev wrote:
> >> The "Simple expression parser" test fails on powerpc
> >> as below:
> >>
> >> parsing metric: #s
On Wed, Oct 16, 2024 at 11:23 AM Athira Rajeev
wrote:
>
>
>
> > On 16 Oct 2024, at 8:36 PM, Ian Rogers wrote:
> >
> > On Wed, Oct 16, 2024 at 5:30 AM Athira Rajeev
> > wrote:
> >>
> >>
> >>
> >>> On 14 Oct 2024, at 10:56 PM
On Wed, Oct 16, 2024 at 5:30 AM Athira Rajeev
wrote:
>
>
>
> > On 14 Oct 2024, at 10:56 PM, Namhyung Kim wrote:
> >
> > Hello Athira,
> >
> > On Sun, Oct 13, 2024 at 11:07:42PM +0530, Athira Rajeev wrote:
> >> perf fails to compile on systems with GCC version11
> >> as below:
> >>
> >> In file in
On Mon, Aug 26, 2024 at 10:33 PM Kajol Jain wrote:
>
> Update JSON/events for power10 platform with additional events.
>
> Signed-off-by: Kajol Jain
For the series:
Reviewed-by: Ian Rogers
Just to note, the moving of events in patches 2 and 3 is necessary as
the filename sets th
On Mon, Jul 22, 2024 at 10:27 PM Kajol Jain wrote:
>
> Update JSON/events for power10 platform with additional events.
> Also move PM_VECTOR_LD_CMPL event from others.json to
> frontend.json file.
>
> Signed-off-by: Kajol Jain
Reviewed-by: Ian Rogers
> ---
>
On Fri, Jun 28, 2024 at 11:32 AM Abhishek Dubey wrote:
>
> For printing dump_trace, just use existing stats_print()
> function.
>
> Signed-off-by: Abhishek Dubey
Reviewed-by: Ian Rogers
Thanks,
Ian
> ---
> tools/perf/builtin-report.c | 3 +--
> 1 file changed, 1 i
On Thu, Jun 27, 2024 at 6:37 AM Abhishek Dubey wrote:
>
> For printing dump_trace, just use existing stats_print()
> function.
>
> Signed-off-by: Abhishek Dubey
Thanks Abishek, the change looks good but it needs to be rebased on
top of Commit 411ee13598ef ("perf hist: Add symbol_conf.skip_empty"
hich is not allocated on the cpumask. Fix this by changing
> the size of cpumask to number of possible cpus and not the number
> of online cpus.
>
> Signed-off-by: Athira Rajeev
For the series:
Reviewed-by: Ian Rogers
Thanks,
Ian
> ---
> tools/perf/bench/futex-hash.c |
On Fri, May 31, 2024 at 11:10 PM Athira Rajeev
wrote:
>
> Now perf uses the capstone library to disassemble the instructions in
> x86. capstone is used (if available) for perf annotate to speed up.
> Currently it only supports x86 architecture. Patch includes changes to
> enable this in powerpc. F
On Tue, Dec 5, 2023 at 1:50 PM Arnaldo Carvalho de Melo wrote:
>
> Em Mon, Nov 27, 2023 at 11:12:57AM +, James Clark escreveu:
> > On 23/11/2023 16:02, Athira Rajeev wrote:
> > > --- a/tools/perf/Makefile.perf
> > > @@ -1134,6 +1152,7 @@ bpf-skel-clean:
> > > $(call QUIET_CLEAN, bpf-skel)
On Mon, Dec 4, 2023 at 12:22 PM Arnaldo Carvalho de Melo
wrote:
>
> Em Mon, Dec 04, 2023 at 05:20:46PM -0300, Arnaldo Carvalho de Melo escreveu:
> > Em Mon, Dec 04, 2023 at 12:12:54PM -0800, Ian Rogers escreveu:
> > > On Thu, Nov 23, 2023 at 8:01 AM Athir
On Thu, Nov 23, 2023 at 8:01 AM Athira Rajeev
wrote:
>
> Running "perf list" on powerpc fails with segfault
> as below:
>
>./perf list
>Segmentation fault (core dumped)
>
> This happens because of duplicate events in the json list.
> The powerpc Json event list contains some event with sam
test child finished with 0
> end
> probe libc's inet_pton & backtrace it with ping: Ok
>
> Output where gaih_inet function is present
>
> # ./perf test -v "probe libc's inet_pton & backtrace it with ping"
>
.config. Include the file
> ".config-detected" so that make will use the system detected
> configuration in the CONFIG checks. This will fix isues that
> could arise when other "CONFIG_*" checks are added to Makefile.perf
> in future as well.
>
> Signed-off-
On Fri, Sep 8, 2023 at 7:51 AM Athira Rajeev
wrote:
>
> Makefile.perf uses "CONFIG_*" checks in the code. Example the config
> for libtraceevent is used to set PYTHON_EXT_SRCS
>
> ifeq ($(CONFIG_LIBTRACEEVENT),y)
> PYTHON_EXT_SRCS := $(shell grep -v ^\# util/python-ext-sources)
>
k SC1090 to handle the location of sourced
> files
> tests/shell: Fix shellcheck issues in tests/shell/stat+shadow_stat.sh
> tetscase
> tests/shell: Fix shellcheck warnings for SC2153 in multiple scripts
Series:
Tested-by: Ian Rogers
Thanks,
Ian
> tool
On Thu, Sep 7, 2023 at 10:19 AM Athira Rajeev
wrote:
>
> Makefile.perf uses "CONFIG_*" checks in the code. Example the config
> for libtraceevent is used to set PYTHON_EXT_SRCS
>
> ifeq ($(CONFIG_LIBTRACEEVENT),y)
> PYTHON_EXT_SRCS := $(shell grep -v ^\# util/python-ext-sources)
#x27;commit b50d691e50e6 ("perf test: Fix "all PMU test" to skip
> parametrized events")' which handled a simialr instance with
> "all PMU test".
>
> Fix parse-events test to skip parametrized events since
> it needs proper setup of the parameters.
>
>
On Wed, Aug 23, 2023 at 4:00 AM Naveen N Rao wrote:
>
> Hi Kajol,
>
> On Wed Aug 23, 2023 at 1:21 PM IST, Kajol Jain wrote:
> > Based on commit 7d54a4acd8c1 ("perf test: Skip watchpoint
> > tests if no watchpoints available"), hardware breakpoints
> > are not available for power9 platform and beca
On Sun, Aug 6, 2023 at 9:50 PM Athira Rajeev
wrote:
>
> Testcase "Parsing of all PMU events from sysfs" parse events for
> all PMUs, and not just cpu. In case of powerpc, the PowerVM
> environment supports events from hv_24x7 and hv_gpci PMU which
> is of example format like below:
>
> - hv_24x7/C
On Thu, Aug 17, 2023 at 10:35 AM Athira Rajeev
wrote:
>
>
>
> > On 07-Aug-2023, at 11:07 AM, Sachin Sant wrote:
> >
> >
> >
> >> On 07-Aug-2023, at 10:22 AM, Athira Rajeev
> >> wrote:
> >>
> >> The test "BPF prologue generation" fails as below:
> >>
> >> Writing event: p:perf_bpf_probe/func _t
ke NO_LIBTRACEEVENT=1'),
> > 'perf version --build-options' outputs (output trimmed):
> >
> >...
> > libtraceevent: [ OFF ] # HAVE_LIBTRACEEVENT
> >...
> >
> > While, when perf is compiled WITH libtraceevent,
> >
> >
code from tools/perf/trace/beauty.
> > Other patches are fixes for scripts from tools/perf/tests.
> >
> > The shellcheck is run for severity level for errors and warnings.
> > Command used:
> >
> > # for F in $(find tests/shell/ -perm -o=x -name '*.sh'); do s
On Tue, Jun 13, 2023 at 10:04 AM Athira Rajeev
wrote:
>
> From: Aditya Gupta
>
> Test "perf script task-analyzer tests" fails in environment with missing
> libtraceevent support, as perf record fails to create the perf.data
> file, which further tests depend on.
>
> Instead, when perf is not comp
-events/arch/powerpc/power9/pmc.json:application/json;
> charset=us-ascii
> pmu-events/arch/powerpc/power9/translation.json:application/json;
> charset=us-ascii
>
> Fixes: 3c22ba524304 ("perf vendor events powerpc: Update POWER9 events")
> Reported-by: Ar
On Thu, Mar 23, 2023 at 6:11 AM Arnaldo Carvalho de Melo
wrote:
>
> Exception processing pmu-events/arch/powerpc/power9/other.json
> Traceback (most recent call last):
> File "pmu-events/jevents.py", line 997, in
> main()
> File "pmu-events/jevents.py", line 979, in main
> ftw(arch_pa
#37.48
> EXECUTION_STALL_CPI
> 1,393,916,546,654 PM_DISP_STALL_CYC
> 8,455,376,836,463 PM_EXEC_STALL
>
> "--metric-no-group" is used for forcing PM_RUN_INST_CMPL to be scheduled
> in all group for more accuracy.
>
> Signed-off-by: A
me of the hv-24x7 metric events
> may need bigger workload with system wide monitoring to get the data.
> Fix this issue by changing current system wide check from true workload to
> sleep 0.01 workload.
>
> Result with the patch changes in powerpc:
>
> 98: perf all metrics test
On Tue, Feb 7, 2023 at 7:45 PM kajoljain wrote:
>
>
>
> On 2/6/23 10:10, Athira Rajeev wrote:
> >
> >
> >> On 02-Feb-2023, at 10:14 PM, Kajol Jain wrote:
> >>
> >> Testcase stat_all_metrics.sh fails in powerpc:
> >>
> >> 92: perf all metrics test : FAILED!
> >>
> >> Logs with verbose:
> >>
> >> [
On Fri, Feb 3, 2023 at 12:15 PM Arnaldo Carvalho de Melo
wrote:
>
> Em Thu, Jan 26, 2023 at 03:36:45PM -0800, Ian Rogers escreveu:
> > Add a target that generates a log file for running metric_test.py and
> > make this a dependency on generating pmu-events.c. The log output i
On Fri, Feb 3, 2023 at 8:56 AM Arnaldo Carvalho de Melo wrote:
>
> Em Fri, Feb 03, 2023 at 01:02:02PM -0300, Arnaldo Carvalho de Melo escreveu:
> > Em Fri, Feb 03, 2023 at 12:43:48PM -0300, Arnaldo Carvalho de Melo escreveu:
> > > I tried bisecting, but at this cset:
> > >
> > > acme@roc-rk3399-pc
On Thu, Feb 2, 2023 at 5:40 PM Ian Rogers wrote:
>
> ARM64 overrides a weak function but a previous change had broken the
> build.
>
> Fixes: 8cefeb8bd336 ("perf pmu-events: Introduce pmu_metrics_table")
As 8cefeb8bd336 ("perf pmu-events: Introduce pmu_metrics_ta
ARM64 overrides a weak function but a previous change had broken the
build.
Fixes: 8cefeb8bd336 ("perf pmu-events: Introduce pmu_metrics_table")
Signed-off-by: Ian Rogers
---
tools/perf/arch/arm64/util/pmu.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tools/perf/arch/arm64/
On Mon, Jan 30, 2023 at 7:22 AM John Garry wrote:
>
> On 27/01/2023 13:48, Ian Rogers wrote:
> > On Fri, Jan 27, 2023, 5:20 AM John Garry > <mailto:john.g.ga...@oracle.com>> wrote:
> >
> > On 26/01/2023 23:36, Ian Rogers wrote:
> >
> > Hi I
On Mon, Jan 30, 2023 at 8:07 AM John Garry wrote:
>
> On 26/01/2023 23:36, Ian Rogers wrote:
> > @@ -660,7 +763,29 @@ const struct pmu_events_table
> > *perf_pmu__find_events_table(struct perf_pmu *pmu)
> >
> > const struct pmu_metrics_table *perf_pmu__find_metr
On Fri, Jan 27, 2023, 5:20 AM John Garry wrote:
> On 26/01/2023 23:36, Ian Rogers wrote:
>
> Hi Ian,
>
> At a glance, none of this series has your Signed-off-by tag..
>
> Thanks,
> John
>
Thanks John, will fix. Is there anything else?
Ian
> Add an optimizati
Add a target that generates a log file for running metric_test.py and
make this a dependency on generating pmu-events.c. The log output is
displayed if the test fails like (the test was modified to make it
fail):
```
TEST/tmp/perf/pmu-events/metric_test.log
F..
==
Add quiet_cmd_test so that:
$(Q)$(call echo-cmd,test)
will print:
TEST
This is useful for executing compile-time tests similar to what
happens for fortify tests in the kernel's lib directory.
---
tools/build/Makefile.build | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/build/Makefi
A character encoding issue added a "3D" character that breaks the
metrics test.
Fixes: 40769665b63d ("perf jevents: Parse metrics during conversion")
---
tools/perf/pmu-events/metric_test.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/perf/pmu-events/metric_test.
The #slots literal will return NAN when not on ARM64 which causes a
perf test failure when not on an ARM64 for a JEVENTS_ARCH=all build:
..
10.4: Parsing of PMU event table metrics with fake PMUs : FAILED!
..
Add an is_test boolean so that the failure can be avoided when running
as a t
This allows the set of generated jevents events and metrics be limited
to a subset of the model names. Appropriate if trying to minimize the
binary size where only a set of models are possible.
---
tools/perf/pmu-events/Build | 3 ++-
tools/perf/pmu-events/jevents.py | 14 ++
2 f
Turn a perf json event into an event, metric or both. This reduces the
number of events needed to scan to find an event or metric. As events
no longer need the relatively seldom used metric fields, 4 bytes is
saved per event. This reduces the big C string's size by 335kb (14.8%)
on x86.
Note, for
Add a metrics table that is just a cast from pmu_events_table. This
changes the APIs so that event and metric usage of the underlying
table is different. For the no jevents case the tables are already
separate, later changes will separate the tables for the jevents case.
---
tools/perf/arch/arm64/
Combine into a single function to simplify, in a later change, writing
metrics separately.
---
tools/perf/pmu-events/jevents.py | 36 +---
1 file changed, 14 insertions(+), 22 deletions(-)
diff --git a/tools/perf/pmu-events/jevents.py b/tools/perf/pmu-events/jevents.py
Metrics are their own unit and these variables held broken metrics
previously and now just hold the value NULL. Remove code that used
these variables.
Reviewed-by: John Garry
---
tools/perf/builtin-stat.c | 1 -
tools/perf/util/cgroup.c | 1 -
tools/perf/util/evsel.c | 2 -
Previous changes separated the uses of pmu_event and pmu_metric,
however, both structures contained all the variables of event and
metric. This change removes the event variables from metric and the
metric variables from event.
Note, this change removes the setting of evsel's metric_name/expr as
t
Separate the event and metric table when building without jevents. Add
find_core_metrics_table and perf_pmu__find_metrics_table while
renaming existing utilities to be event specific, so that users can
find the right table for their need.
Reviewed-by: John Garry
---
tools/perf/pmu-events/empty-p
Create a new pmu_metric for the metric related variables from
pmu_event but that is initially just a clone of pmu_event. Add
iterators for pmu_metric and use in places that metrics are desired
rather than events. Make the event iterator skip metric only events,
and the metric iterator skip event on
Rewrite metrics within the same file in terms of each other. For example, on
Power8
other_stall_cpi is rewritten from:
"PM_CMPLU_STALL / PM_RUN_INST_CMPL - PM_CMPLU_STALL_BRU_CRU / PM_RUN_INST_CMPL
- PM_CMPLU_STALL_FXU / PM_RUN_INST_CMPL - PM_CMPLU_STALL_VSU / PM_RUN_INST_CMPL
- PM_CMPLU_STALL_L
Add RewriteMetricsInTermsOfOthers that iterates over pairs of names
and expressions trying to replace an expression, within the current
expression, with its name.
---
tools/perf/pmu-events/metric.py | 73 +++-
tools/perf/pmu-events/metric_test.py | 10
2 files cha
rhs may not be defined, say for source_count, so add a guard.
Reviewed-by: Kajol Jain
---
tools/perf/pmu-events/metric.py | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/tools/perf/pmu-events/metric.py b/tools/perf/pmu-events/metric.py
index 4797ed4fd817..2f2fd220e843 10
porate review comments from John Garry
, in particular breaking apart patch 4
into 3 patches. The no jevents breakage and then later fix is
avoided in this series too.
v2. Rebase. Modify the code that skips rewriting a metric with the
same name with itself, to make the name check
On Thu, Jan 26, 2023 at 7:59 AM John Garry wrote:
>
> On 26/01/2023 01:18, Ian Rogers wrote:
> > Add RewriteMetricsInTermsOfOthers that iterates over pairs of names
> > and expressions trying to replace an expression, within the current
> > expression, with its name.
&g
test.
Fixes: acef233b7ca7 ("perf pmu: Add #slots literal support for arm64")
Signed-off-by: Ian Rogers
---
tools/perf/tests/pmu-events.c | 1 +
tools/perf/util/expr.h| 1 +
tools/perf/util/expr.l| 8 +---
3 files changed, 7 insertions(+), 3 deletions(-)
diff --g
This allows the set of generated jevents events and metrics be limited
to a subset of the model names. Appropriate if trying to minimize the
binary size where only a set of models are possible.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/Build | 3 ++-
tools/perf/pmu-events
, for the test PMU architecture pme_test_soc_cpu is renamed
pmu_events__test_soc_cpu for consistency with the event vs metric
naming convention.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/jevents.py | 244 +++
tools/perf/tests/pmu-events.c| 3 +-
2
Add a metrics table that is just a cast from pmu_events_table. This
changes the APIs so that event and metric usage of the underlying
table is different. For the no jevents case the tables are already
separate, later changes will separate the tables for the jevents case.
Signed-off-by: Ian Rogers
Combine into a single function to simplify, in a later change, writing
metrics separately.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/jevents.py | 36 +---
1 file changed, 14 insertions(+), 22 deletions(-)
diff --git a/tools/perf/pmu-events/jevents.py b
Metrics are their own unit and these variables held broken metrics
previously and now just hold the value NULL. Remove code that used
these variables.
Reviewed-by: John Garry
Signed-off-by: Ian Rogers
---
tools/perf/builtin-stat.c | 1 -
tools/perf/util/cgroup.c | 1 -
tools/perf
738f42f96a130079bc951b3cc78c5b8a#n425
Reviewed-by: John Garry
Signed-off-by: Ian Rogers
---
tools/perf/builtin-list.c | 20 ++---
tools/perf/pmu-events/jevents.py | 20 +
tools/perf/pmu-events/pmu-events.h | 22 +--
tools/perf/tests/pmu-even
Separate the event and metric table when building without jevents. Add
find_core_metrics_table and perf_pmu__find_metrics_table while
renaming existing utilities to be event specific, so that users can
find the right table for their need.
Reviewed-by: John Garry
Signed-off-by: Ian Rogers
only events.
Reviewed-by: John Garry
Signed-off-by: Ian Rogers
---
tools/perf/arch/powerpc/util/header.c| 4 +-
tools/perf/pmu-events/empty-pmu-events.c | 49 ++-
tools/perf/pmu-events/jevents.py | 62 -
tools/perf/pmu-events/pmu-events.h | 26
tools/perf
on Power9.
To avoid recomputation decorate the function with a cache.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/jevents.py | 21 -
1 file changed, 16 insertions(+), 5 deletions(-)
diff --git a/tools/perf/pmu-events/jevents.py b/tools/perf/pmu-events/jevents.p
Add RewriteMetricsInTermsOfOthers that iterates over pairs of names
and expressions trying to replace an expression, within the current
expression, with its name.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/metric.py | 73 +++-
tools/perf/pmu-events
rhs may not be defined, say for source_count, so add a guard.
Reviewed-by: Kajol Jain
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/metric.py | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/tools/perf/pmu-events/metric.py b/tools/perf/pmu-events/metric.py
index
wed-by
John Garry and Kajol
Jain.
v3. Rebase an incorporate review comments from John Garry
, in particular breaking apart patch 4
into 3 patches. The no jevents breakage and then later fix is
avoided in this series too.
v2. Rebase. Modify the code that skips rewriting a metric w
This allows the set of generated jevents events and metrics be limited
to a subset of the model names. Appropriate if trying to minimize the
binary size where only a set of models are possible. On ARM64 the
--model selects the implementor rather than model.
Signed-off-by: Ian Rogers
---
tools
, for the test PMU architecture pme_test_soc_cpu is renamed
pmu_events__test_soc_cpu for consistency with the event vs metric
naming convention.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/jevents.py | 244 +++
tools/perf/tests/pmu-events.c| 3 +-
2
Add a metrics table that is just a cast from pmu_events_table. This
changes the APIs so that event and metric usage of the underlying
table is different. For the no jevents case the tables are already
separate, later changes will separate the tables for the jevents case.
Signed-off-by: Ian Rogers
Combine into a single function to simplify, in a later change, writing
metrics separately.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/jevents.py | 36 +---
1 file changed, 14 insertions(+), 22 deletions(-)
diff --git a/tools/perf/pmu-events/jevents.py b
Metrics are their own unit and these variables held broken metrics
previously and now just hold the value NULL. Remove code that used
these variables.
Reviewed-by: John Garry
Signed-off-by: Ian Rogers
---
tools/perf/builtin-stat.c | 1 -
tools/perf/util/cgroup.c | 1 -
tools/perf
or metrics [2] but given the lack of use of such a feature,
let's clean the code and just remove.
[1] https://lore.kernel.org/lkml/20220707195610.303254-1-irog...@google.com/
[2]
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/tools/perf/util/stat-shadow.c?id=01
Separate the event and metric table when building without jevents. Add
find_core_metrics_table and perf_pmu__find_metrics_table while
renaming existing utilities to be event specific, so that users can
find the right table for their need.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events
only events.
Signed-off-by: Ian Rogers
---
tools/perf/arch/powerpc/util/header.c| 4 +-
tools/perf/pmu-events/empty-pmu-events.c | 49 ++-
tools/perf/pmu-events/jevents.py | 62 -
tools/perf/pmu-events/pmu-events.h | 26
tools/perf/tests/pmu-events.c
on Power9.
To avoid recomputation decorate the function with a cache.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/jevents.py | 21 -
1 file changed, 16 insertions(+), 5 deletions(-)
diff --git a/tools/perf/pmu-events/jevents.py b/tools/perf/pmu-events/jevents.p
Add RewriteMetricsInTermsOfOthers that iterates over pairs of names
and expressions trying to replace an expression, within the current
expression, with its name.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/metric.py | 73 +++-
tools/perf/pmu-events
rhs may not be defined, say for source_count, so add a guard.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/metric.py | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/tools/perf/pmu-events/metric.py b/tools/perf/pmu-events/metric.py
index 4797ed4fd817
ents breakage and then later fix is
avoided in this series too.
v2. Rebase. Modify the code that skips rewriting a metric with the
same name with itself, to make the name check case insensitive.
Ian Rogers (11):
perf jevents metric: Correct Function equality
perf jevents metric: Add abil
On Mon, Jan 23, 2023 at 5:26 AM John Garry wrote:
>
> On 21/12/2022 22:34, Ian Rogers wrote:
> > Add an optimization to jevents using the metric code, rewrite metrics
> > in terms of each other in order to minimize size and improve
> > readability. For example, on Power
On Mon, Jan 23, 2023 at 7:18 AM John Garry wrote:
>
> On 21/12/2022 22:34, Ian Rogers wrote:
> > Turn a perf json event into an event, metric or both. This reduces the
> > number of events needed to scan to find an event or metric. As events
> > no longer need the relat
On Mon, Jan 23, 2023 at 7:36 AM John Garry wrote:
>
> On 21/12/2022 22:34, Ian Rogers wrote:
> > Add a metrics table that is just a cast from pmu_events_table. This
> > changes the APIs so that event and metric usage of the underlying
> > table is different. Later changes
On Mon, Jan 23, 2023 at 7:16 AM John Garry wrote:
>
> On 21/12/2022 22:34, Ian Rogers wrote:
> > Previously both events and metrics were encoded in struct
> > pmu_event. Create a new pmu_metric that has the metric related
> > variables and remove these from pmu_
On Wed, Dec 21, 2022 at 2:34 PM Ian Rogers wrote:
>
> Add an optimization to jevents using the metric code, rewrite metrics
> in terms of each other in order to minimize size and improve
> readability. For example, on Power8
> other_stall_cpi is rewritten from:
&g
On Mon, Jan 16, 2023 at 4:00 AM Athira Rajeev
wrote:
>
>
>
> > On 16-Jan-2023, at 11:47 AM, Ian Rogers wrote:
> >
> > On Sun, Jan 15, 2023 at 9:03 PM Athira Rajeev
> > wrote:
> >>
> >>
> >>
> >>> On 28-Sep-2022, at 10:24
On Sun, Jan 15, 2023 at 9:03 PM Athira Rajeev
wrote:
>
>
>
> > On 28-Sep-2022, at 10:24 AM, Athira Rajeev
> > wrote:
> >
> > Hi All,
> >
> > Looking for what direction we can take here.
> > Do we want to change all tests in tools/perf/tests/shell except
> > test_intel_pt.sh to use "bash" or go
This allows the set of generated jevents events and metrics be limited
to a subset of the model names. Appropriate if trying to minimize the
binary size where only a set of models are possible.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/Build | 3 ++-
tools/perf/pmu-events
igned-off-by: Ian Rogers
---
tools/perf/pmu-events/jevents.py | 244 +++
tools/perf/tests/pmu-events.c| 3 +-
2 files changed, 189 insertions(+), 58 deletions(-)
diff --git a/tools/perf/pmu-events/jevents.py b/tools/perf/pmu-events/jevents.py
index be2cf8a
: Ok
70: Event expansion for cgroups : Ok
caused by the necessary test metrics not being found.
Signed-off-by: Ian Rogers
---
tools/perf/arch/arm64/util/pmu.c | 23 ++-
tools/perf/pmu-events/empty-pmu-events.c | 52
Combine into a single function to simplify, in a later change, writing
metrics separately.
Signed-off-by: Ian Rogers
---
tools/perf/pmu-events/jevents.py | 36 +---
1 file changed, 14 insertions(+), 22 deletions(-)
diff --git a/tools/perf/pmu-events/jevents.py b
1 - 100 of 123 matches
Mail list logo