1. 08 10月, 2011 2 次提交
    • A
      perf top: Add callgraph support · 19d4ac3c
      Arnaldo Carvalho de Melo 提交于
      Just like in 'perf report', but live.
      
      Still needs to decay the callchains, but already somewhat useful as-is.
      
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      Link: http://lkml.kernel.org/n/tip-cj3rmaf5jpsvi3v0tf7t4uvp@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      19d4ac3c
    • A
      perf top: Reuse the 'report' hist_entry/hists classes · ab81f3fd
      Arnaldo Carvalho de Melo 提交于
      This actually fixes several problems we had in the old 'perf top':
      
      1. Unresolved symbols not show, limitation that came from the old
         "KernelTop" codebase, to solve it we would need to do changes
         that would make sym_entry have most of the hist_entry fields.
      2. It was using the number of samples, not the sum of sample->period.
      
      And brings the --sort code that allows us to have all the views in
      'perf report', for instance:
      
      [root@emilia ~]# perf top --sort dso
      PerfTop: 5903 irqs/sec kernel:77.5% exact: 0.0% [1000Hz cycles], (all, 8 CPUs)
      ------------------------------------------------------------------------------
      
          31.59%  libcrypto.so.1.0.0
          21.55%  [kernel]
          18.57%  libpython2.6.so.1.0
           7.04%  libc-2.12.so
           6.99%  _backend_agg.so
           4.72%  sshd
           1.48%  multiarray.so
           1.39%  libfreetype.so.6.3.22
           1.37%  perf
           0.71%  libgobject-2.0.so.0.2200.5
           0.53%  [tg3]
           0.48%  libglib-2.0.so.0.2200.5
           0.44%  libstdc++.so.6.0.13
           0.40%  libcairo.so.2.10800.8
           0.38%  libm-2.12.so
           0.34%  umath.so
           0.30%  libgdk-x11-2.0.so.0.1800.9
           0.22%  libpthread-2.12.so
           0.20%  libgtk-x11-2.0.so.0.1800.9
           0.20%  librt-2.12.so
           0.15%  _path.so
           0.13%  libpango-1.0.so.0.2800.1
           0.11%  libatlas.so.3.0
           0.09%  ft2font.so
           0.09%  libpangoft2-1.0.so.0.2800.1
           0.08%  libX11.so.6.3.0
           0.07%  [vdso]
           0.06%  cyclictest
      ^C
      
      All the filter lists can be used as well: --dsos, --comms, --symbols,
      etc.
      
      The 'perf report' TUI is also reused, being possible to apply all the
      zoom operations, do annotation, etc.
      
      This change will allow multiple simplifications in the symbol system as
      well, that will be detailed in upcoming changesets.
      
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      Link: http://lkml.kernel.org/n/tip-xzaaldxq7zhqrrxdxjifk1mh@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      ab81f3fd
  2. 07 10月, 2011 5 次提交
  3. 30 9月, 2011 17 次提交
  4. 24 9月, 2011 13 次提交
  5. 18 8月, 2011 3 次提交
    • S
      perf stat: Add -o and --append options · 4aa9015f
      Stephane Eranian 提交于
      This patch adds an option (-o) to save the output of perf stat into a
      file. You could do this with perf record but not with perf stat.
      Instead, you had to fiddle with stderr to save the counts into a
      separate file.
      
      The patch also adds the --append option so that results can be
      concatenated into a single file across runs. Each run of the tool is
      clearly separated by a comment line starting with a hash mark. The -A
      option of perf record is already used by perf stat, so we only add a
      long option.
      
      $ perf stat -o res.txt date
      $ cat res.txt
      
       Performance counter stats for 'date':
      
                0.791306 task-clock                #    0.668 CPUs utilized
                       2 context-switches          #    0.003 M/sec
                       0 CPU-migrations            #    0.000 M/sec
                     197 page-faults               #    0.249 M/sec
                 1878143 cycles                    #    2.373 GHz
         <not supported> stalled-cycles-frontend
         <not supported> stalled-cycles-backend
                 1083367 instructions              #    0.58  insns per cycle
                  193027 branches                  #  243.935 M/sec
                    9014 branch-misses             #    4.67% of all branches
      
             0.001184746 seconds time elapsed
      
      The option can be combined with -x to make the output file much easier
      to parse.
      
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Link: http://lkml.kernel.org/r/20110815202233.GA18535@quadSigned-off-by: NStephane Eranian <eranian@google.com>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      4aa9015f
    • S
      perf annotate: Add --symfs option · e71a0598
      Stephane Eranian 提交于
      If you have --symfs in perf report, then you also need it for perf
      annotate.  This allows off-box assembly level analysis of perf.data
      samples.
      
      This patch complements:
      
      commit ec5761ea
      Author: David Ahern <daahern@cisco.com>
      Date:   Thu Dec 9 13:27:07 2010 -0700
      
          perf symbols: Add symfs option for off-box analysis using specified tree
      Acked-by: NDavid Ahern <daahern@cisco.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: David Ahern <daahern@cisco.com>
      Link: http://lkml.kernel.org/r/20110729232040.GA21838@quadSigned-off-by: NStephane Eranian <eranian@google.com>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      e71a0598
    • S
      perf annotate: Make output more readable · 3e6a2a7f
      Stephane Eranian 提交于
      This patch adds two new options to perf annotate:
      	- --no-asm-raw : Do not display raw instruction encodings
      	- --no-source  : Do not interleave source code with assembly code
      
      We believe those options make the output of annotate more readable.
      
      Systematically displaying source can make it hard to follow code and
      especially optimized code.
      
      Raw encodings are not useful in most cases.
      
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Link: http://lkml.kernel.org/r/20110517153207.GA9834@quadSigned-off-by: NStephane Eranian <eranian@google.com>
      [committer note: Use the 'no-' option inverting logic]
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      3e6a2a7f