From: Jin Yao <yao.jin@linux.intel.com>
To: acme@kernel.org, jolsa@kernel.org, peterz@infradead.org,
mingo@redhat.com, alexander.shishkin@linux.intel.com
Cc: Linux-kernel@vger.kernel.org, ak@linux.intel.com,
kan.liang@intel.com, yao.jin@intel.com,
Jin Yao <yao.jin@linux.intel.com>
Subject: [PATCH v1 0/2] perf annotate: add max/min cycles
Date: Thu, 17 May 2018 22:58:36 +0800 [thread overview]
Message-ID: <1526569118-14217-1-git-send-email-yao.jin@linux.intel.com> (raw)
Currently perf has a feature to account cycles for LBRs
For example, on skylake,
perf record -b ...
perf report or
perf annotate
And then browsing the annotate browser gives average cycle counts
for program blocks.
For some analysis it would be useful if we could know not only
the average cycles but also the max and min cycles.
Now, for example, when press 'c', the annotate view is:
Percent│ IPC Cycle(max/min)
│
│
│ Disassembly of section .text:
│
│ 000000000003aab0 <random@@GLIBC_2.2.5>:
8.22 │3.92 sub $0x18,%rsp
│3.92 mov $0x1,%esi
│3.92 xor %eax,%eax
│3.92 cmpl $0x0,argp_program_version_hook@@G
│3.92 1(2/1) ↓ je 20
│ lock cmpxchg %esi,__abort_msg@@GLIBC_P
│ ↓ jne 29
│ ↓ jmp 43
│1.10 20: cmpxchg %esi,__abort_msg@@GLIBC_PRIVATE+
8.93 │1.10 1(5/1) ↓ je 43
When press 'c' again, the annotate view is switched back:
Percent│ IPC Cycle
│
│
│ Disassembly of section .text:
│
│ 000000000003aab0 <random@@GLIBC_2.2.5>:
8.22 │3.92 sub $0x18,%rsp
│3.92 mov $0x1,%esi
│3.92 xor %eax,%eax
│3.92 cmpl $0x0,argp_program_version_hook@@GLIBC_2.2.5+0x
│3.92 1 ↓ je 20
│ lock cmpxchg %esi,__abort_msg@@GLIBC_PRIVATE+0x8a0
│ ↓ jne 29
│ ↓ jmp 43
│1.10 20: cmpxchg %esi,__abort_msg@@GLIBC_PRIVATE+0x8a0
8.93 │1.10 1 ↓ je 43
Jin Yao (2):
perf annotate: Record the max/min cycles
perf annotate: Create hotkey 'c' to show max/min cycles
tools/perf/ui/browsers/annotate.c | 8 ++++++
tools/perf/util/annotate.c | 51 +++++++++++++++++++++++++++++++++------
tools/perf/util/annotate.h | 11 ++++++++-
3 files changed, 62 insertions(+), 8 deletions(-)
--
2.7.4
next reply other threads:[~2018-05-17 7:04 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-17 14:58 Jin Yao [this message]
2018-05-17 14:58 ` [PATCH v1 1/2] perf annotate: Record the " Jin Yao
2018-05-19 11:46 ` [tip:perf/core] perf annotate: Record the min/max cycles tip-bot for Jin Yao
2018-05-17 14:58 ` [PATCH v1 2/2] perf annotate: Create hotkey 'c' to show max/min cycles Jin Yao
2018-05-17 20:06 ` Arnaldo Carvalho de Melo
2018-05-18 0:15 ` Jin, Yao
2018-05-19 11:46 ` [tip:perf/core] perf annotate: Create hotkey 'c' to show min/max cycles tip-bot for Jin Yao
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=1526569118-14217-1-git-send-email-yao.jin@linux.intel.com \
--to=yao.jin@linux.intel.com \
--cc=Linux-kernel@vger.kernel.org \
--cc=acme@kernel.org \
--cc=ak@linux.intel.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=jolsa@kernel.org \
--cc=kan.liang@intel.com \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=yao.jin@intel.com \
/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
Powered by JetHome