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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-70d110d775993ff1f63905bbdbc70e3f6bd8da8a@git.kernel.org>
Date:   Sat, 1 Jul 2017 01:51:28 -0700
From:   tip-bot for Adrian Hunter <tipbot@...or.com>
To:     linux-tip-commits@...r.kernel.org
Cc:     mingo@...nel.org, acme@...hat.com, hpa@...or.com,
        adrian.hunter@...el.com, ak@...ux.intel.com, tglx@...utronix.de,
        linux-kernel@...r.kernel.org
Subject: [tip:perf/core] perf auxtrace: Add itrace option to output power
 events

Commit-ID:  70d110d775993ff1f63905bbdbc70e3f6bd8da8a
Gitweb:     http://git.kernel.org/tip/70d110d775993ff1f63905bbdbc70e3f6bd8da8a
Author:     Adrian Hunter <adrian.hunter@...el.com>
AuthorDate: Fri, 26 May 2017 11:17:25 +0300
Committer:  Arnaldo Carvalho de Melo <acme@...hat.com>
CommitDate: Tue, 27 Jun 2017 12:09:58 -0300

perf auxtrace: Add itrace option to output power events

Add itrace option to output power events.

Signed-off-by: Adrian Hunter <adrian.hunter@...el.com>
Cc: Andi Kleen <ak@...ux.intel.com>
Link: http://lkml.kernel.org/r/1495786658-18063-25-git-send-email-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
---
 tools/perf/Documentation/itrace.txt | 5 +++--
 tools/perf/util/auxtrace.c          | 4 ++++
 tools/perf/util/auxtrace.h          | 2 ++
 3 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/tools/perf/Documentation/itrace.txt b/tools/perf/Documentation/itrace.txt
index deafd16..a3abe04 100644
--- a/tools/perf/Documentation/itrace.txt
+++ b/tools/perf/Documentation/itrace.txt
@@ -4,13 +4,14 @@
 		r	synthesize branches events (returns only)
 		x	synthesize transactions events
 		w	synthesize ptwrite events
+		p	synthesize power events
 		e	synthesize error events
 		d	create a debug log
 		g	synthesize a call chain (use with i or x)
 		l	synthesize last branch entries (use with i or x)
 		s       skip initial number of events
 
-	The default is all events i.e. the same as --itrace=ibxwe
+	The default is all events i.e. the same as --itrace=ibxwpe
 
 	In addition, the period (default 100000) for instructions events
 	can be specified in units of:
@@ -28,7 +29,7 @@
 	instructions or transactions events can be specified.
 
 	It is also possible to skip events generated (instructions, branches, transactions,
-	ptwrite) at the beginning. This is useful to ignore initialization code.
+	ptwrite, power) at the beginning. This is useful to ignore initialization code.
 
 	--itrace=i0nss1000000
 
diff --git a/tools/perf/util/auxtrace.c b/tools/perf/util/auxtrace.c
index baad91e..651c01d 100644
--- a/tools/perf/util/auxtrace.c
+++ b/tools/perf/util/auxtrace.c
@@ -948,6 +948,7 @@ void itrace_synth_opts__set_default(struct itrace_synth_opts *synth_opts)
 	synth_opts->branches = true;
 	synth_opts->transactions = true;
 	synth_opts->ptwrites = true;
+	synth_opts->pwr_events = true;
 	synth_opts->errors = true;
 	synth_opts->period_type = PERF_ITRACE_DEFAULT_PERIOD_TYPE;
 	synth_opts->period = PERF_ITRACE_DEFAULT_PERIOD;
@@ -1034,6 +1035,9 @@ int itrace_parse_synth_opts(const struct option *opt, const char *str,
 		case 'w':
 			synth_opts->ptwrites = true;
 			break;
+		case 'p':
+			synth_opts->pwr_events = true;
+			break;
 		case 'e':
 			synth_opts->errors = true;
 			break;
diff --git a/tools/perf/util/auxtrace.h b/tools/perf/util/auxtrace.h
index b48afb2..68e0aa4 100644
--- a/tools/perf/util/auxtrace.h
+++ b/tools/perf/util/auxtrace.h
@@ -60,6 +60,7 @@ enum itrace_period_type {
  * @branches: whether to synthesize 'branches' events
  * @transactions: whether to synthesize events for transactions
  * @ptwrites: whether to synthesize events for ptwrites
+ * @pwr_events: whether to synthesize power events
  * @errors: whether to synthesize decoder error events
  * @dont_decode: whether to skip decoding entirely
  * @log: write a decoding log
@@ -81,6 +82,7 @@ struct itrace_synth_opts {
 	bool			branches;
 	bool			transactions;
 	bool			ptwrites;
+	bool			pwr_events;
 	bool			errors;
 	bool			dont_decode;
 	bool			log;

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ