The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Namhyung Kim <namhyung@kernel.org>
To: Arnaldo Carvalho de Melo <acme@kernel.org>,
	Ian Rogers <irogers@google.com>,
	Kan Liang <kan.liang@linux.intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Ingo Molnar <mingo@kernel.org>,
	LKML <linux-kernel@vger.kernel.org>,
	linux-perf-users@vger.kernel.org, Leo Yan <leo.yan@arm.com>,
	James Clark <james.clark@linaro.org>
Subject: [PATCH 2/3] perf test: Move some ARM tests to arch/arm64/tests/shell
Date: Thu, 22 May 2025 10:10:43 -0700	[thread overview]
Message-ID: <20250522171044.1075583-2-namhyung@kernel.org> (raw)
In-Reply-To: <20250522171044.1075583-1-namhyung@kernel.org>

The test_arm_callgraph_fp.sh checks with aarch64 so it should belong to
there.  And IIRC ARM SPE is supported on 64-bit platforms so move the
tests too.  But I'm not sure about coresight so left them.

Also please test it with shellcheck as I couldn't run it actually.

Cc: Leo Yan <leo.yan@arm.com>
Cc: James Clark <james.clark@linaro.org>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
---
 tools/perf/arch/arm64/tests/Build                  | 14 ++++++++++++++
 .../arm64}/tests/shell/test_arm_callgraph_fp.sh    |  4 ++--
 .../{ => arch/arm64}/tests/shell/test_arm_spe.sh   |  0
 .../arm64}/tests/shell/test_arm_spe_fork.sh        |  0
 4 files changed, 16 insertions(+), 2 deletions(-)
 rename tools/perf/{ => arch/arm64}/tests/shell/test_arm_callgraph_fp.sh (89%)
 rename tools/perf/{ => arch/arm64}/tests/shell/test_arm_spe.sh (100%)
 rename tools/perf/{ => arch/arm64}/tests/shell/test_arm_spe_fork.sh (100%)

diff --git a/tools/perf/arch/arm64/tests/Build b/tools/perf/arch/arm64/tests/Build
index d44c9de92d425c62..6c73720cb0ffa99d 100644
--- a/tools/perf/arch/arm64/tests/Build
+++ b/tools/perf/arch/arm64/tests/Build
@@ -3,3 +3,17 @@ perf-test-$(CONFIG_DWARF_UNWIND) += dwarf-unwind.o
 
 perf-test-y += arch-tests.o
 perf-test-y += cpuid-match.o
+
+ifdef SHELLCHECK
+  SHELL_TESTS := $(shell find shell -executable -type f -name '*.sh')
+  SHELL_TEST_LOGS := $(SHELL_TESTS:tests/shell/%=shell/%.shellcheck_log)
+else
+  SHELL_TESTS :=
+  SHELL_TEST_LOGS :=
+endif
+
+$(OUTPUT)%.shellcheck_log: %
+	$(call rule_mkdir)
+	$(Q)$(call echo-cmd,test)shellcheck -a -S warning "$<" > $@ || (cat $@ && rm $@ && false)
+
+perf-test-y += $(SHELL_TEST_LOGS)
diff --git a/tools/perf/tests/shell/test_arm_callgraph_fp.sh b/tools/perf/arch/arm64/tests/shell/test_arm_callgraph_fp.sh
similarity index 89%
rename from tools/perf/tests/shell/test_arm_callgraph_fp.sh
rename to tools/perf/arch/arm64/tests/shell/test_arm_callgraph_fp.sh
index 9caa36130175964e..f59ab293d67b9f9c 100755
--- a/tools/perf/tests/shell/test_arm_callgraph_fp.sh
+++ b/tools/perf/arch/arm64/tests/shell/test_arm_callgraph_fp.sh
@@ -3,8 +3,8 @@
 # SPDX-License-Identifier: GPL-2.0
 
 shelldir=$(dirname "$0")
-# shellcheck source=lib/perf_has_symbol.sh
-. "${shelldir}"/lib/perf_has_symbol.sh
+# shellcheck source=../../../../tests/shell/lib/perf_has_symbol.sh
+. "${shelldir}"/../../../../tests/shell/lib/perf_has_symbol.sh
 
 if [ "$(uname -m)" != "aarch64" ]; then
 	exit 2
diff --git a/tools/perf/tests/shell/test_arm_spe.sh b/tools/perf/arch/arm64/tests/shell/test_arm_spe.sh
similarity index 100%
rename from tools/perf/tests/shell/test_arm_spe.sh
rename to tools/perf/arch/arm64/tests/shell/test_arm_spe.sh
diff --git a/tools/perf/tests/shell/test_arm_spe_fork.sh b/tools/perf/arch/arm64/tests/shell/test_arm_spe_fork.sh
similarity index 100%
rename from tools/perf/tests/shell/test_arm_spe_fork.sh
rename to tools/perf/arch/arm64/tests/shell/test_arm_spe_fork.sh
-- 
2.49.0.1164.gab81da1b16-goog


  reply	other threads:[~2025-05-22 17:10 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-22 17:10 [PATCH 1/3] perf test: Support arch-specific shell tests Namhyung Kim
2025-05-22 17:10 ` Namhyung Kim [this message]
2025-05-23 10:30   ` [PATCH 2/3] perf test: Move some ARM tests to arch/arm64/tests/shell James Clark
2025-05-22 17:10 ` [PATCH 3/3] perf test: Add AMD IBS sw filter test Namhyung Kim
2025-05-22 20:09 ` [PATCH 1/3] perf test: Support arch-specific shell tests Ian Rogers
2025-05-23 10:48   ` James Clark
2025-05-23 16:50     ` Arnaldo Carvalho de Melo
2025-05-23 21:36       ` Namhyung Kim
2025-05-23 17:54     ` Ian Rogers
2025-05-23 21:33       ` Namhyung Kim
2025-05-23 10:05 ` James Clark

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250522171044.1075583-2-namhyung@kernel.org \
    --to=namhyung@kernel.org \
    --cc=acme@kernel.org \
    --cc=adrian.hunter@intel.com \
    --cc=irogers@google.com \
    --cc=james.clark@linaro.org \
    --cc=jolsa@kernel.org \
    --cc=kan.liang@linux.intel.com \
    --cc=leo.yan@arm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox