1. 10 11月, 2012 4 次提交
  2. 09 11月, 2012 10 次提交
    • Z
      perf test: fix a build error on builtin-test · 12f8f74b
      Zheng Liu 提交于
      Recently I build perf and get a build error on builtin-test.c. The error is as
      following:
      
      $ make
          CC perf.o
          CC builtin-test.o
      cc1: warnings being treated as errors
      builtin-test.c: In function ‘sched__get_first_possible_cpu’:
      builtin-test.c:977: warning: implicit declaration of function ‘CPU_ALLOC’
      builtin-test.c:977: warning: nested extern declaration of ‘CPU_ALLOC’
      builtin-test.c:977: warning: assignment makes pointer from integer without a cast
      builtin-test.c:978: warning: implicit declaration of function ‘CPU_ALLOC_SIZE’
      builtin-test.c:978: warning: nested extern declaration of ‘CPU_ALLOC_SIZE’
      builtin-test.c:979: warning: implicit declaration of function ‘CPU_ZERO_S’
      builtin-test.c:979: warning: nested extern declaration of ‘CPU_ZERO_S’
      builtin-test.c:982: warning: implicit declaration of function ‘CPU_FREE’
      builtin-test.c:982: warning: nested extern declaration of ‘CPU_FREE’
      builtin-test.c:992: warning: implicit declaration of function ‘CPU_ISSET_S’
      builtin-test.c:992: warning: nested extern declaration of ‘CPU_ISSET_S’
      builtin-test.c:998: warning: implicit declaration of function ‘CPU_CLR_S’
      builtin-test.c:998: warning: nested extern declaration of ‘CPU_CLR_S’
      make: *** [builtin-test.o] Error 1
      
      This problem is introduced in 3e7c439a. CPU_ALLOC and related macros are
      missing in sched__get_first_possible_cpu function. In 54489c18, commiter
      mentioned that CPU_ALLOC has been removed. So CPU_ALLOC calls in this
      function are removed to let perf to be built.
      Signed-off-by: NVinson Lee <vlee@twitter.com>
      Signed-off-by: NZheng Liu <wenqing.lz@taobao.com>
      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>
      Cc: Vinson Lee <vlee@twitter.com>
      Cc: Zheng Liu <wenqing.lz@taobao.com>
      Cc: stable@vger.kernel.org
      Link: http://lkml.kernel.org/r/1352422726-31114-1-git-send-email-vlee@twitter.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      12f8f74b
    • A
      perf machine: Move more methods to machine.[ch] · 69d2591a
      Arnaldo Carvalho de Melo 提交于
      This time out of map.[ch] mostly, just code move plus a buch of 'self'
      removal, using machine or machines instead.
      
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Namhyung Kim <namhyung@gmail.com>
      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-j1vtux3vnu6wzmrjutpxnjcz@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      69d2591a
    • A
      perf diff: Use hists__link when not pairing just with baseline · bfaef4b4
      Arnaldo Carvalho de Melo 提交于
      Previously there were blind spots because we were not looking at symbols
      that didn't ocurred in the latest run:
      
        # perf record usleep 1
        [ perf record: Woken up 1 times to write data ]
        [ perf record: Captured and wrote 0.018 MB perf.data (~801 samples) ]
        # perf record usleep 1
        [ perf record: Woken up 1 times to write data ]
        [ perf record: Captured and wrote 0.018 MB perf.data (~801 samples) ]
      
      Before:
      
        # perf diff
        # Event 'cycles'
        #
        # Baseline    Delta      Shared Object                         Symbol
        # ........  .......  .................  .............................
        #
                    +10.38%  [kernel.kallsyms]  [k] get_empty_filp
                     +9.51%  [kernel.kallsyms]  [k] update_sd_lb_stats
                     +9.41%  libpopt.so.0.0.0   [.] _init
                     +9.29%  [kernel.kallsyms]  [k] vma_interval_tree_insert
             9.05%   +0.12%  [kernel.kallsyms]  [k] do_sys_open
                     +9.14%  [kernel.kallsyms]  [k] kfree
                     +8.98%  [kernel.kallsyms]  [k] free_pages_and_swap_cache
                     +8.78%  [kernel.kallsyms]  [k] unmap_page_range
             9.36%   -0.90%  [kernel.kallsyms]  [k] zap_pte_range
             7.60%   +0.09%  [kernel.kallsyms]  [k] find_next_bit
                     +4.37%  [kernel.kallsyms]  [k] place_entity
                     +3.38%  [kernel.kallsyms]  [k] __do_page_fault
                     +0.80%  [kernel.kallsyms]  [k] native_apic_mem_write
             0.21%   +0.43%  [kernel.kallsyms]  [k] native_write_msr_safe
        #
      
      So 9.05 + 9.36 + 7.60 + 0.21 != 100%
      
      Now using the recently introduced hists__link we can see the whole
      picture:
      
        # perf diff
        # Event 'cycles'
        #
        # Baseline    Delta      Shared Object                         Symbol
        # ........  .......  .................  .............................
        #
             8.44%   -8.44%  [kernel.kallsyms]  [k] _raw_spin_lock
             9.05%   -9.05%  [kernel.kallsyms]  [k] sha_transform
            10.55%  -10.55%  [kernel.kallsyms]  [k] __d_lookup_rcu
                    +10.38%  [kernel.kallsyms]  [k] get_empty_filp
            17.70%  -17.70%  [kernel.kallsyms]  [k] kmem_cache_free
                     +9.51%  [kernel.kallsyms]  [k] update_sd_lb_stats
                     +9.41%  libpopt.so.0.0.0   [.] _init
                     +9.29%  [kernel.kallsyms]  [k] vma_interval_tree_insert
             9.05%   +0.12%  [kernel.kallsyms]  [k] do_sys_open
                     +9.14%  [kernel.kallsyms]  [k] kfree
                     +8.98%  [kernel.kallsyms]  [k] free_pages_and_swap_cache
                     +8.78%  [kernel.kallsyms]  [k] unmap_page_range
             9.36%   -0.90%  [kernel.kallsyms]  [k] zap_pte_range
             7.60%   +0.09%  [kernel.kallsyms]  [k] find_next_bit
                     +4.37%  [kernel.kallsyms]  [k] place_entity
                     +3.38%  [kernel.kallsyms]  [k] __do_page_fault
             4.01%   -4.01%  [kernel.kallsyms]  [k] handle_pte_fault
             9.27%   -9.27%  [kernel.kallsyms]  [k] find_get_page
             0.78%   -0.78%  [kernel.kallsyms]  [k] rcu_irq_enter
             0.57%   -0.57%  [kernel.kallsyms]  [k] finish_task_switch
             4.25%   -4.25%  [kernel.kallsyms]  [k] run_timer_softirq
                     +0.80%  [kernel.kallsyms]  [k] native_apic_mem_write
             0.21%   +0.43%  [kernel.kallsyms]  [k] native_write_msr_safe
             9.16%   -9.16%  ld-2.12.so         [.] close
        #
      
      Now:
      
      8.44 + 9.05 + 10.55 + 17.70 + 9.05 + 9.36 +
      7.60 + 4.01 + 9.27 + 0.78 + 0.57 + 4.25 + 0.21 + 9.16 == 100%
      
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Namhyung Kim <namhyung@gmail.com>
      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-jeq55qdgby1745bs8r9sscdh@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      bfaef4b4
    • A
      perf hists: Introduce hists__link · 494d70a1
      Arnaldo Carvalho de Melo 提交于
      That given two hists will find the hist_entries (buckets) in the second
      hists that are for the same bucket in the first and link them, then it
      will look for all buckets in the second that don't have a counterpart in
      the first and will create a dummy counterpart that will then be linked
      to the entry in the second.
      
      For multiple events this will be done pairing the leader with all the
      other events in the group, so that in the end the leader will have all
      the buckets in all the hists in a group, dummy or not while the other
      hists will be left untouched.
      
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Namhyung Kim <namhyung@gmail.com>
      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-l9l9ieozqdhn9lieokd95okw@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      494d70a1
    • A
      perf diff: Move hists__match to the hists lib · 95529be4
      Arnaldo Carvalho de Melo 提交于
      Its not 'diff' specific and will be useful for other use cases, like
      bucketizing multiple events in a single session.
      
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Namhyung Kim <namhyung@gmail.com>
      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-o35urjgxfxxm70aw1wa81s4w@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      95529be4
    • A
      perf diff: Start moving to support matching more than two hists · b821c732
      Arnaldo Carvalho de Melo 提交于
      We want to match more than two hists, so that we can match more than two
      perf.data files and moreover, match hist_entries (buckets) in multiple
      events in a group.
      
      So the "baseline"/"leader" will instead of a ->pair pointer, use a
      list_head, that will link to the pairs and hists__match use it.
      
      Following that perf_evlist__link will link the hists in its evsel
      groups.
      
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Namhyung Kim <namhyung@gmail.com>
      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-2kbmzepoi544ygj9godseqpv@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      b821c732
    • N
      perf tools: Don't try to lookup objdump for live mode · ff6f7778
      Namhyung Kim 提交于
      Arnaldo reported that annotation during perf top resulted in a segfault.
      It was because the env->arch was NULL and we don't set it for a live
      session.  In fact, no need to look up objdump in this case since we can
      use system's default (native) objdump.
      Reported-by: NArnaldo Carvalho de Melo <acme@ghostprotocols.net>
      Signed-off-by: NNamhyung Kim <namhyung@kernel.org>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Irina Tirdea <irina.tirdea@gmail.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1352251815-12615-1-git-send-email-namhyung@kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      ff6f7778
    • A
      perf tools: Add arbitary aliases and support names with - · eef9ba98
      Andi Kleen 提交于
      - Add missing scanner symbol for arbitrary aliases inside the config
        region.
      
      - looks nicer than _, so allow - in the event names. Used for various of
        the arch perfmon and Haswell events.
      Signed-off-by: NAndi Kleen <ak@linux.intel.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Namhyung Kim <namhyung.kim@lge.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Link: http://lkml.kernel.org/r/1352123463-7346-6-git-send-email-eranian@google.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      eef9ba98
    • J
      perf tools: Add LIBDW_DIR Makefile variable to for alternate libdw · 1fa0bc3f
      Jiri Olsa 提交于
      Adding LIBDW_DIR Makefile variable to be able to specify
      alternate libdw library location.
      
      To use it run make like:
        $ make LIBDW_DIR=/opt/libdw/
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/n/tip-n2uv8c9ti6b26fioaw2rq5yv@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      1fa0bc3f
    • J
      perf tests: Move attr.py temp dir cleanup into finally section · d4fcf0a8
      Jiri Olsa 提交于
      Currently if there's 'Unsup' exception raised, we do not clean up the
      temp directory. Solving this by adding 'finally' to make the cleanup in
      any case.
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1352390461-15404-1-git-send-email-jolsa@redhat.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      d4fcf0a8
  3. 08 11月, 2012 3 次提交
  4. 06 11月, 2012 18 次提交
  5. 02 11月, 2012 5 次提交