Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

perf test: Make parallel testing the default

Now C tests can have the "exclusive" flag to run without other tests,
and shell tests can add "(exclusive)" to their description, run tests
in parallel by default. Tests which flake when run in parallel can be
marked exclusive to resolve the problem.

Non-scientifically, the reduction on `perf test` execution time is
from 8m35.890s to 3m55.115s on a Tigerlake laptop. So the tests
complete in less than half the time.

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-9-irogers@google.com
Signed-off-by: Namhyung Kim <namhyung@kernel.org>

authored by

Ian Rogers and committed by
Namhyung Kim
94d1a913 79e72f38

+2 -11
+2 -11
tools/perf/tests/builtin-test.c
··· 40 40 * making them easier to debug. 41 41 */ 42 42 static bool dont_fork; 43 - /* Don't fork the tests in parallel and wait for their completion. */ 44 - static bool sequential = true; 43 + /* Fork the tests in parallel and wait for their completion. */ 44 + static bool sequential; 45 45 const char *dso_to_test; 46 46 const char *test_objdump_path = "objdump"; 47 47 ··· 639 639 const char *skip = NULL; 640 640 const char *workload = NULL; 641 641 bool list_workloads = false; 642 - /* 643 - * Run tests in parallel, lacks infrastructure to avoid running tests 644 - * that clash for resources, So leave it as the developers choice to 645 - * enable while working on the needed infra. 646 - */ 647 - bool parallel = false; 648 642 const struct option test_options[] = { 649 643 OPT_STRING('s', "skip", &skip, "tests", "tests to skip"), 650 644 OPT_INCR('v', "verbose", &verbose, 651 645 "be more verbose (show symbol address, etc)"), 652 646 OPT_BOOLEAN('F', "dont-fork", &dont_fork, 653 647 "Do not fork for testcase"), 654 - OPT_BOOLEAN('p', "parallel", &parallel, "Run the tests in parallel"), 655 648 OPT_BOOLEAN('S', "sequential", &sequential, 656 649 "Run the tests one after another rather than in parallel"), 657 650 OPT_STRING('w', "workload", &workload, "work", "workload to run for testing, use '--list-workloads' to list the available ones."), ··· 681 688 682 689 if (dont_fork) 683 690 sequential = true; 684 - else if (parallel) 685 - sequential = false; 686 691 687 692 symbol_conf.priv_size = sizeof(int); 688 693 symbol_conf.try_vmlinux_path = true;