Skip to content

Commit 451ed80

Browse files
athira-rajeevacmel
authored andcommitted
perf test: Fix "all PMU test" to skip hv_24x7/hv_gpci tests on powerpc
"perf all PMU test" picks the input events from "perf list --raw-dump pmu" list and runs "perf stat -e" for each of the event in the list. 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/CPM_ADJUNCT_INST,domain=?,core=?/ - hv_gpci/event,partition_id=?/ The value for "?" needs to be filled in depending on system and respective event. CPM_ADJUNCT_INST needs have core value and domain value. hv_gpci event needs partition_id. Similarly, there are other events for hv_24x7 and hv_gpci having "?" in event format. Hence skip these events on powerpc platform since values like partition_id, domain is specific to system and event. Fixes: 3d5ac9e ("perf test: Workload test of all PMUs") Signed-off-by: Athira Jajeev <atrajeev@linux.vnet.ibm.com> Acked-by: Ian Rogers <irogers@google.com> Cc: Disha Goel <disgoel@linux.vnet.ibm.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Kajol Jain <kjain@linux.ibm.com> Cc: linuxppc-dev@lists.ozlabs.org Cc: Madhavan Srinivasan <maddy@linux.vnet.ibm.com> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Nageswara R Sastry <rnsastry@linux.ibm.com> Link: https://lore.kernel.org/r/20220520101236.17249-1-atrajeev@linux.vnet.ibm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 parent 92d579e commit 451ed80

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

tools/perf/tests/shell/stat_all_pmu.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,16 @@
55
set -e
66

77
for p in $(perf list --raw-dump pmu); do
8+
# In powerpc, skip the events for hv_24x7 and hv_gpci.
9+
# These events needs input values to be filled in for
10+
# core, chip, partition id based on system.
11+
# Example: hv_24x7/CPM_ADJUNCT_INST,domain=?,core=?/
12+
# hv_gpci/event,partition_id=?/
13+
# Hence skip these events for ppc.
14+
if echo "$p" |grep -Eq 'hv_24x7|hv_gpci' ; then
15+
echo "Skipping: Event '$p' in powerpc"
16+
continue
17+
fi
818
echo "Testing $p"
919
result=$(perf stat -e "$p" true 2>&1)
1020
if ! echo "$result" | grep -q "$p" && ! echo "$result" | grep -q "<not supported>" ; then

0 commit comments

Comments
 (0)