linux-perf-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/1] Fix number of events displayed in header
@ 2012-03-20 19:23 Ashay Rane
  2012-03-20 19:42 ` Arnaldo Carvalho de Melo
  0 siblings, 1 reply; 10+ messages in thread
From: Ashay Rane @ 2012-03-20 19:23 UTC (permalink / raw)
  To: linux-perf-users, Peter Zijlstra, Paul Mackerras, Ingo Molnar,
	Arnaldo Carvalho de Melo
  Cc: linux-kernel, Ashay Rane

From: Ashay Rane <ashay.rane@tacc.utexas.edu>

Signed-off-by: Ashay Rane <ashay.rane@tacc.utexas.edu>
---
 tools/perf/builtin-report.c |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c
index 25d34d4..58a20cf 100644
--- a/tools/perf/builtin-report.c
+++ b/tools/perf/builtin-report.c
@@ -202,11 +202,9 @@ static size_t hists__fprintf_nr_sample_events(struct hists *self,
 					      const char *evname, FILE *fp)
 {
 	size_t ret;
-	char unit;
-	unsigned long nr_events = self->stats.nr_events[PERF_RECORD_SAMPLE];
+	u64 total_period = self->stats.total_period;
 
-	nr_events = convert_unit(nr_events, &unit);
-	ret = fprintf(fp, "# Events: %lu%c", nr_events, unit);
+	ret = fprintf(fp, "# Events: %llu", total_period);
 	if (evname != NULL)
 		ret += fprintf(fp, " %s", evname);
 	return ret + fprintf(fp, "\n#\n");
-- 
1.7.4.1

^ permalink raw reply related	[flat|nested] 10+ messages in thread
* [PATCH 1/1] Fix number of events displayed in header
@ 2012-03-13 22:24 Ashay Rane
  0 siblings, 0 replies; 10+ messages in thread
From: Ashay Rane @ 2012-03-13 22:24 UTC (permalink / raw)
  To: linux-perf-users
  Cc: Peter Zijlstra, Paul Mackerras, Ingo Molnar,
	Arnaldo Carvalho de Melo, linux-kernel, Ashay Rane

Signed-off-by: Ashay Rane <ashay.rane@tacc.utexas.edu>
---
 tools/perf/builtin-report.c |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c
index 25d34d4..58a20cf 100644
--- a/tools/perf/builtin-report.c
+++ b/tools/perf/builtin-report.c
@@ -202,11 +202,9 @@ static size_t hists__fprintf_nr_sample_events(struct hists *self,
 					      const char *evname, FILE *fp)
 {
 	size_t ret;
-	char unit;
-	unsigned long nr_events = self->stats.nr_events[PERF_RECORD_SAMPLE];
+	u64 total_period = self->stats.total_period;
 
-	nr_events = convert_unit(nr_events, &unit);
-	ret = fprintf(fp, "# Events: %lu%c", nr_events, unit);
+	ret = fprintf(fp, "# Events: %llu", total_period);
 	if (evname != NULL)
 		ret += fprintf(fp, " %s", evname);
 	return ret + fprintf(fp, "\n#\n");
-- 
1.7.4.1

^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2012-03-20 20:27 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-20 19:23 [PATCH 1/1] Fix number of events displayed in header Ashay Rane
2012-03-20 19:42 ` Arnaldo Carvalho de Melo
2012-03-20 19:46   ` David Ahern
2012-03-20 19:47     ` Peter Zijlstra
2012-03-20 19:51       ` Ashay Rane
2012-03-20 19:59         ` Peter Zijlstra
2012-03-20 20:04           ` Ashay Rane
2012-03-20 20:09             ` Peter Zijlstra
2012-03-20 20:27               ` Ashay Rane
  -- strict thread matches above, loose matches on Subject: below --
2012-03-13 22:24 Ashay Rane

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).