From: Johan Tibell <johan.tibell@gmail.com>
To: linux-perf-users@vger.kernel.org
Subject: 'annotate' confusingly reports 'add' instruction as taking most CPU time
Date: Mon, 30 Sep 2013 21:06:56 -0700 [thread overview]
Message-ID: <CAK-tuPbbbWcbJxk88xO_urj2ktk861xnG+tkOs0cZBjnowjMeA@mail.gmail.com> (raw)
Hi,
I'm trying to use 'perf record' to find the hotspot inside a function.
The results I'm seeing are confusing. 'annotate' claims that a simple
'add' instruction is the main CPU time consumer"
0.00 : 408246: mov 0x8(%rbp),%rsi
0.31 :
40824a: mov 0x10(%rbp),%rcx
0.00 : 40824e:
lea 0x4(%rcx),%rdi
0.81 : 408252: mov
0x6(%rbx),%rbx
0.00 : 408256: mov
0x18(%rbx,%rax,8),%r8
---> 27.58 : 40825b: add $0x20,%rbp
0.00 : 40825f: jmpq 408338 <Main_zdwpolyzugo_info>
0.00 : 408264:
mov $0x7b9609,%ebx
0.00 : 408269: add
$0x20,%rbp
0.00 : 40826d: jmpq *0x0(%rbp)
5.41 : 408270: mov 0xd(%rbx),%rax
How shall I interpret this? Is it really the following jump that is to blame?
-- Johan
next reply other threads:[~2013-10-01 4:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-01 4:06 Johan Tibell [this message]
2013-10-01 12:53 ` 'annotate' confusingly reports 'add' instruction as taking most CPU time Vince Weaver
2013-10-01 15:14 ` Johan Tibell
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=CAK-tuPbbbWcbJxk88xO_urj2ktk861xnG+tkOs0cZBjnowjMeA@mail.gmail.com \
--to=johan.tibell@gmail.com \
--cc=linux-perf-users@vger.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).