Re: [PATCH 2/2 v2] perf test: Skip perf test 114 perf record test subtest test_leader_sampling for s390

From: James Clark
Date: Wed Jan 29 2025 - 06:25:38 EST




On 29/01/2025 7:11 am, Thomas Richter wrote:
On s390 the event instructions can not be used for recording.
This event is only supported by perf stat.

Omit subtest test_leader_sampling on s390.

Signed-off-by: Thomas Richter <tmricht@xxxxxxxxxxxxx>
---
tools/perf/tests/shell/record.sh | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/perf/tests/shell/record.sh b/tools/perf/tests/shell/record.sh
index 957ee10aff44..9e645eb09d9e 100755
--- a/tools/perf/tests/shell/record.sh
+++ b/tools/perf/tests/shell/record.sh
@@ -307,7 +307,8 @@ test_system_wide
test_workload
test_branch_counter
test_cgroup
-test_leader_sampling
+# On s390 event instructions can not be used for recording
+[ $(uname -m) != s390x ] && test_leader_sampling
test_topdown_leader_sampling
test_precise_max

I still think we should use the cycles event instead of skipping. My intention was to use the most commonly available event with 80fd0c1eac7 ("perf tests: Make leader sampling test work without branch event"), it's not important which event is used exactly