linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@infradead.org>
To: Ingo Molnar <mingo@kernel.org>
Cc: linux-kernel@vger.kernel.org, Pekka Enberg <penberg@kernel.org>,
	David Ahern <dsahern@gmail.com>, Ingo Molnar <mingo@redhat.com>,
	Arnaldo Carvalho de Melo <acme@redhat.com>
Subject: [PATCH 01/10] perf trace: Tweak summary output
Date: Thu, 14 Nov 2013 17:25:06 -0300	[thread overview]
Message-ID: <1384460715-23198-2-git-send-email-acme@infradead.org> (raw)
In-Reply-To: <1384460715-23198-1-git-send-email-acme@infradead.org>

From: Pekka Enberg <penberg@kernel.org>

Tweak the summary output as suggested by Ingo Molnar:

  [penberg@localhost ~]$ perf trace -a --duration 10000 --summary -- sleep 1
  ^C
   Summary of events:

   Xorg (817), 148 events, 0.0%, 0.000 msec

     syscall            calls      min       avg       max      stddev
                                 (msec)    (msec)    (msec)        (%)
     --------------- -------- --------- --------- ---------     ------
     read                   7     0.002     0.004     0.011     32.00%
     rt_sigprocmask        40     0.001     0.001     0.002      1.31%
     ioctl                  6     0.002     0.003     0.005     19.45%
     writev                 7     0.004     0.018     0.059     43.76%
     select                 9     0.000    74.513   507.869     74.61%
     setitimer              4     0.001     0.002     0.002     10.08%

Suggested-by: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Pekka Enberg <penberg@kernel.org>
Acked-by: Ingo Molnar <mingo@kernel.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Ingo Molnar <mingo@redhat.com>
Link: http://lkml.kernel.org/r/1384345308-24404-1-git-send-email-penberg@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/builtin-trace.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index 6b230af940e2..8be17fc462ba 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -2112,9 +2112,9 @@ static size_t thread__dump_stats(struct thread_trace *ttrace,
 
 	printed += fprintf(fp, "\n");
 
-	printed += fprintf(fp, "                                                    msec/call\n");
-	printed += fprintf(fp, "   syscall            calls      min      avg      max stddev\n");
-	printed += fprintf(fp, "   --------------- -------- -------- -------- -------- ------\n");
+	printed += fprintf(fp, "   syscall            calls      min       avg       max      stddev\n");
+	printed += fprintf(fp, "                               (msec)    (msec)    (msec)        (%%)\n");
+	printed += fprintf(fp, "   --------------- -------- --------- --------- ---------     ------\n");
 
 	/* each int_node is a syscall */
 	while (inode) {
@@ -2131,9 +2131,9 @@ static size_t thread__dump_stats(struct thread_trace *ttrace,
 
 			sc = &trace->syscalls.table[inode->i];
 			printed += fprintf(fp, "   %-15s", sc->name);
-			printed += fprintf(fp, " %8" PRIu64 " %8.3f %8.3f",
+			printed += fprintf(fp, " %8" PRIu64 " %9.3f %9.3f",
 					   n, min, avg);
-			printed += fprintf(fp, " %8.3f %6.2f\n", max, pct);
+			printed += fprintf(fp, " %9.3f %9.2f%%\n", max, pct);
 		}
 
 		inode = intlist__next(inode);
-- 
1.8.1.4


  reply	other threads:[~2013-11-14 20:25 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-14 20:25 [GIT PULL 00/10] perf/core improvements and fixes Arnaldo Carvalho de Melo
2013-11-14 20:25 ` Arnaldo Carvalho de Melo [this message]
2013-11-14 20:25 ` [PATCH 02/10] perf tools: Remove trivial extra semincolon Arnaldo Carvalho de Melo
2013-11-14 20:25 ` [PATCH 03/10] perf top: Add missing newline if the 'uid' is invalid Arnaldo Carvalho de Melo
2013-11-14 20:25 ` [PATCH 04/10] perf tools: Synthesize anon MMAP records again Arnaldo Carvalho de Melo
2013-11-14 20:25 ` [PATCH 05/10] perf tools: Use perf_evlist__{first,last}, perf_evsel__next Arnaldo Carvalho de Melo
2013-11-14 20:25 ` [PATCH 06/10] perf evsel: Introduce perf_evsel__prev() method Arnaldo Carvalho de Melo
2013-11-14 20:25 ` [PATCH 07/10] perf symbols: Limit max callchain using max_stack on DWARF unwinding too Arnaldo Carvalho de Melo
2013-11-14 20:25 ` [PATCH 08/10] perf ui browser: Fix segfault caused by off by one handling END key Arnaldo Carvalho de Melo
2013-11-14 20:25 ` [PATCH 09/10] perf probe: Add '--demangle'/'--no-demangle' Arnaldo Carvalho de Melo
2013-11-14 20:25 ` [PATCH 10/10] perf record: Add an option to force per-cpu mmaps Arnaldo Carvalho de Melo
2013-11-15  6:06   ` Ingo Molnar
2013-11-15 11:00     ` Adrian Hunter
2013-11-15 11:10       ` Ingo Molnar
2013-11-15 11:27         ` Adrian Hunter
2013-11-15 11:56           ` Ingo Molnar
2013-11-15 12:03             ` Peter Zijlstra
2013-11-15 12:05               ` Ingo Molnar
2013-11-15 12:30                 ` Peter Zijlstra
2013-11-15 12:33                 ` Adrian Hunter
2013-11-15 12:52               ` Adrian Hunter
2013-11-15 12:53                 ` Peter Zijlstra
2013-11-15 13:52       ` [PATCH V2] perf record: Make per-cpu mmaps the default Adrian Hunter
2013-11-30 12:50         ` [tip:perf/core] " tip-bot for Adrian Hunter
2013-11-15  6:38 ` [GIT PULL 00/10] perf/core improvements and fixes Ingo Molnar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1384460715-23198-2-git-send-email-acme@infradead.org \
    --to=acme@infradead.org \
    --cc=acme@redhat.com \
    --cc=dsahern@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=mingo@redhat.com \
    --cc=penberg@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).