summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Rogers <irogers@google.com>2024-10-25 12:21:02 -0700
committerNamhyung Kim <namhyung@kernel.org>2024-10-28 09:32:57 -0700
commitd50318fe00d176c5ee5de9092ca092bee05a9eb6 (patch)
tree46bae2826585fee55c54ad43c8e5e909e9e04e70
parent0e036dcad4e62b89f8df3e41402babb9345521af (diff)
perf test: Reduce scope of parallel variable
The variable duplicates sequential but is only used for command line argument processing. Reduce scope to make the behavior clearer. Tested-by: James Clark <james.clark@linaro.org> Signed-off-by: Ian Rogers <irogers@google.com> Cc: Colin Ian King <colin.i.king@gmail.com> Cc: Howard Chu <howardchu95@gmail.com> Cc: Weilin Wang <weilin.wang@intel.com> Cc: Ilya Leoshkevich <iii@linux.ibm.com> Cc: Thomas Richter <tmricht@linux.ibm.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: Dapeng Mi <dapeng1.mi@linux.intel.com> Cc: Athira Jajeev <atrajeev@linux.vnet.ibm.com> Cc: Michael Petlan <mpetlan@redhat.com> Cc: Veronika Molnarova <vmolnaro@redhat.com> Link: https://lore.kernel.org/r/20241025192109.132482-4-irogers@google.com Signed-off-by: Namhyung Kim <namhyung@kernel.org>
-rw-r--r--tools/perf/tests/builtin-test.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/tools/perf/tests/builtin-test.c b/tools/perf/tests/builtin-test.c
index 57d2e9e03fbce..0e8f877f4b1f0 100644
--- a/tools/perf/tests/builtin-test.c
+++ b/tools/perf/tests/builtin-test.c
@@ -41,9 +41,6 @@
static bool dont_fork;
/* Don't fork the tests in parallel and wait for their completion. */
static bool sequential = true;
-/* Do it in parallel, lacks infrastructure to avoid running tests that clash for resources,
- * So leave it as the developers choice to enable while working on the needed infra */
-static bool parallel;
const char *dso_to_test;
const char *test_objdump_path = "objdump";
@@ -578,6 +575,12 @@ int cmd_test(int argc, const char **argv)
const char *skip = NULL;
const char *workload = NULL;
bool list_workloads = false;
+ /*
+ * Run tests in parallel, lacks infrastructure to avoid running tests
+ * that clash for resources, So leave it as the developers choice to
+ * enable while working on the needed infra.
+ */
+ bool parallel = false;
const struct option test_options[] = {
OPT_STRING('s', "skip", &skip, "tests", "tests to skip"),
OPT_INCR('v', "verbose", &verbose,