mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [QUESTION] perf annotate: how do we fix the 'total period' feature ?
@ 2017-07-05  5:47 Taeung Song
  2017-07-05  6:07 ` Namhyung Kim
  0 siblings, 1 reply; 3+ messages in thread
From: Taeung Song @ 2017-07-05  5:47 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo; +Cc: LKML, Namhyung Kim, Jiri Olsa, Milian Wolff

Hi,

Two problems of perf-annotate were mentioned in recent PATCH reviews
by Milian and Namhyung.

Currently perf-annotate has a '--show-total-period' option
and a 't' key "Toggle total period view" on TUI browser.

However, they actually show the number of samples, not period(Raw number 
of event count of sample).
So it's a different number to the perf report like below.

For example,

   $ perf report --stdio --show-nr-sample --show-total-period -S hex2u64
...
# Overhead       Samples        Period  Command  Shared Object
# ........  ............  ............  .......  .............
#
      3.07%            36      26484668  perf     perf


   $ perf annotate  --stdio --show-total-period -s hex2u64
  Percent |      Source code & Disassembly of perf for cycles:ppp (36 
samples)
-----------------------------------------------------------------------------
          :
          :
          :
          :      Disassembly of section .text:
          :
          :      000000000053ef9e <hex2u64>:
          :      hex2u64():
        0 :        53ef9e:       push   %rbp
        0 :        53ef9f:       mov    %rsp,%rbp
        0 :        53efa2:       sub    $0x30,%rsp
        1 :        53efa6:       callq  424810 
<pthread_attr_setdetachstate@plt+0x10>
        0 :        53efab:       mov    %rdi,-0x28(%rbp)
        2 :        53efaf:       mov    %rsi,-0x30(%rbp)
...

Problems:
   1) the total period of perf-annotate is different from perf-report's
   2) perf-annotate only shows the first column as 'Percent'
      (even though the number of samples for each addr are actually printed)

So we need to just rename it ? ('total period' -> 'samples')

Or,
we should enable perf-annotate to support both features for 'periods' 
and 'samples' ?


Thanks,
Taeung

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

end of thread, other threads:[~2017-07-05  6:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-05  5:47 [QUESTION] perf annotate: how do we fix the 'total period' feature ? Taeung Song
2017-07-05  6:07 ` Namhyung Kim
2017-07-05  6:50   ` Taeung Song

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®