lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180502151942.20542-14-acme@kernel.org>
Date:   Wed,  2 May 2018 12:19:03 -0300
From:   Arnaldo Carvalho de Melo <acme@...nel.org>
To:     Ingo Molnar <mingo@...nel.org>
Cc:     Clark Williams <williams@...hat.com>, linux-kernel@...r.kernel.org,
        linux-perf-users@...r.kernel.org,
        Hendrik Brueckner <brueckner@...ux.ibm.com>,
        Michael Petlan <mpetlan@...hat.com>,
        linux-s390@...r.kernel.org,
        Arnaldo Carvalho de Melo <acme@...hat.com>
Subject: [PATCH 13/52] perf tests: Let 'perf test list' display subtests

From: Hendrik Brueckner <brueckner@...ux.ibm.com>

The output of perf test and perf test list differ because perf test list
does not display subtests.  Correct this behavior and also let perf test
list report subtests.

For example:

	$ ./perf test 2>&1 |wc -l
	65

Without this commit:
	$ ./perf test list 2>&1 |wc -l
	57

With this commit:
	$ ./perf test list 2>&1 |wc -l
	65

Signed-off-by: Hendrik Brueckner <brueckner@...ux.ibm.com>
Reviewed-by: Thomas Richter <tmricht@...ux.ibm.com>
Acked-by: Jiri Olsa <jolsa@...nel.org>
Cc: Michael Petlan <mpetlan@...hat.com>
Cc: linux-s390@...r.kernel.org
LPU-Reference: 1523605343-11970-1-git-send-email-brueckner@...ux.ibm.com
Link: https://lkml.kernel.org/n/tip-efb74jw7x2xs2bucp5hf4ilu@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
---
 tools/perf/tests/builtin-test.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/tools/perf/tests/builtin-test.c b/tools/perf/tests/builtin-test.c
index cac8f8889bc3..2bde505e2e7e 100644
--- a/tools/perf/tests/builtin-test.c
+++ b/tools/perf/tests/builtin-test.c
@@ -654,6 +654,15 @@ static int perf_test__list(int argc, const char **argv)
 			continue;
 
 		pr_info("%2d: %s\n", i, t->desc);
+
+		if (t->subtest.get_nr) {
+			int subn = t->subtest.get_nr();
+			int subi;
+
+			for (subi = 0; subi < subn; subi++)
+				pr_info("%2d:%1d: %s\n", i, subi + 1,
+					t->subtest.get_desc(subi));
+		}
 	}
 
 	perf_test__list_shell(argc, argv, i);
-- 
2.14.3

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ