From: tip-bot for Christian Borntraeger <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: acme@redhat.com, linux-kernel@vger.kernel.org, hpa@zytor.com,
mingo@kernel.org, jolsa@kernel.org, borntraeger@de.ibm.com,
pbonzini@redhat.com, dsahern@gmail.com, tglx@linutronix.de
Subject: [tip:perf/core] perf kvm stat: Properly show submicrosecond times
Date: Tue, 12 Aug 2014 22:13:11 -0700 [thread overview]
Message-ID: <tip-b048a24cc8f29dce1bad564aaeb8680020d3701c@git.kernel.org> (raw)
In-Reply-To: <1406805231-10675-2-git-send-email-borntraeger@de.ibm.com>
Commit-ID: b048a24cc8f29dce1bad564aaeb8680020d3701c
Gitweb: http://git.kernel.org/tip/b048a24cc8f29dce1bad564aaeb8680020d3701c
Author: Christian Borntraeger <borntraeger@de.ibm.com>
AuthorDate: Thu, 31 Jul 2014 13:13:51 +0200
Committer: Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Sat, 2 Aug 2014 10:21:11 -0300
perf kvm stat: Properly show submicrosecond times
For lots of exits the min time (and sometimes max) is 0 or 1. Lets
increase the accurancy similar to what the average field alread does.
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Acked-by: David Ahern <dsahern@gmail.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: kvm@vger.kernel.org
Link: http://lkml.kernel.org/r/1406805231-10675-2-git-send-email-borntraeger@de.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-kvm.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/tools/perf/builtin-kvm.c b/tools/perf/builtin-kvm.c
index 43367eb..fe92dfd 100644
--- a/tools/perf/builtin-kvm.c
+++ b/tools/perf/builtin-kvm.c
@@ -592,8 +592,8 @@ static void print_result(struct perf_kvm_stat *kvm)
pr_info("%9s ", "Samples%");
pr_info("%9s ", "Time%");
- pr_info("%10s ", "Min Time");
- pr_info("%10s ", "Max Time");
+ pr_info("%11s ", "Min Time");
+ pr_info("%11s ", "Max Time");
pr_info("%16s ", "Avg time");
pr_info("\n\n");
@@ -610,8 +610,8 @@ static void print_result(struct perf_kvm_stat *kvm)
pr_info("%10llu ", (unsigned long long)ecount);
pr_info("%8.2f%% ", (double)ecount / kvm->total_count * 100);
pr_info("%8.2f%% ", (double)etime / kvm->total_time * 100);
- pr_info("%8" PRIu64 "us ", min / 1000);
- pr_info("%8" PRIu64 "us ", max / 1000);
+ pr_info("%9.2fus ", (double)min / 1e3);
+ pr_info("%9.2fus ", (double)max / 1e3);
pr_info("%9.2fus ( +-%7.2f%% )", (double)etime / ecount/1e3,
kvm_event_rel_stddev(vcpu, event));
pr_info("\n");
prev parent reply other threads:[~2014-08-13 5:13 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-31 11:13 [RFC] increase perf kvm stat accuracy Christian Borntraeger
2014-07-31 11:13 ` [PATCH/RFC] KVM: perf/stat: Properly show submicrosecond times Christian Borntraeger
2014-07-31 14:24 ` David Ahern
2014-07-31 14:43 ` Arnaldo Carvalho de Melo
2014-08-13 5:13 ` tip-bot for Christian Borntraeger [this message]
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=tip-b048a24cc8f29dce1bad564aaeb8680020d3701c@git.kernel.org \
--to=tipbot@zytor.com \
--cc=acme@redhat.com \
--cc=borntraeger@de.ibm.com \
--cc=dsahern@gmail.com \
--cc=hpa@zytor.com \
--cc=jolsa@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=pbonzini@redhat.com \
--cc=tglx@linutronix.de \
/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