1. 04 10月, 2010 2 次提交
  2. 10 9月, 2010 1 次提交
  3. 08 9月, 2010 2 次提交
  4. 27 8月, 2010 1 次提交
    • F
      perf: Initialize callchains roots's childen hits · 5225c458
      Frederic Weisbecker 提交于
      Each histogram entry has a callchain root that stores the
      callchain samples. However we forgot to initialize the
      tracking of children hits of these roots, which then got
      random values on their creation.
      
      The root children hits is multiplied by the minimum percentage
      of hits provided by the user, and the result becomes the minimum
      hits expected from children branches. If the random value due
      to the uninitialization is big enough, then this minimum number
      of hits can be huge and eventually filter every children branches.
      
      The end result was invisible callchains. All we need to
      fix this is to initialize the children hits of the root.
      Reported-by: NChristoph Hellwig <hch@infradead.org>
      Signed-off-by: NFrederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: 2.6.32.x-2.6.35.y <stable@kernel.org>
      5225c458
  5. 16 8月, 2010 1 次提交
    • A
      perf annotate tui: Fix exit and RIGHT keys handling · e9184621
      Arnaldo Carvalho de Melo 提交于
      As part of ongoing effort to reduce the coupling with libnewt, browsers
      are being changed to return the exit key.
      
      The annotate browser is not returning it as expected by builtin-annotate
      when annotating multiple symbols (when 'perf annotate' is called without
      specifying a symbol name).
      
      Fix it by returning the exit key and also adding the RIGHT key as a exit
      key so that going to the next symbol in the TUI can work again.
      
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      LKML-Reference: <new-submission>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      e9184621
  6. 13 8月, 2010 1 次提交
    • I
      perf: Add back list_head data types · 88d89da6
      Ingo Molnar 提交于
      This commit:
      
       de5d9bf6: Move list types from <linux/list.h> to <linux/types.h>.
      
      Moved the list head data types out of list.h, breaking the build.
      Add them to the perf types.h as well.
      
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      LKML-Reference: <new-submission>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      88d89da6
  7. 11 8月, 2010 13 次提交
  8. 07 8月, 2010 4 次提交
  9. 06 8月, 2010 7 次提交
  10. 04 8月, 2010 2 次提交
    • S
      perf: expose event__process function · b83f920e
      Srikar Dronamraju 提交于
      The event__process function is useful in processing /proc/<pid>/maps.  All of
      the functions that are called from event__process are defined in util/event.c.
      Though its defined in builtin-top.c, it could be reused for perf probe for
      uprobes. Hence moving it to util/event.c and exporting the function.
      
      LKML-Reference: <20100802123851.GD22812@linux.vnet.ibm.com>
      Signed-off-by: NSrikar Dronamraju <srikar@linux.vnet.ibm.com>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      b83f920e
    • D
      perf events: Fix mmap offset determination · b5a63254
      Dave Martin 提交于
      Fix buggy-looking code which unnecessarily adjusts the file offset
      fields read from /proc/*/maps.
      
      This may have gone unnoticed since the offset is usually 0 (and the
      logic in util/symbol.c may work incorrectly for other offset values).
      
      Commiter note:
      
      This fixes a bug introduced in 4af8b35d, there is no need to shift pgoff
      twice, the show_map_vma routine in fs/proc/task_mmu.c already converts
      it from the number of pages to the size in bytes, and that is what
      appears in /proc/PID/map.
      
      Cc: Nicolas Pitre <nicolas.pitre@linaro.org>
      Cc: Will Deacon <Will.Deacon@arm.com>
      LKML-Reference: <1280836116-6654-2-git-send-email-dave.martin@linaro.org>
      Signed-off-by: NDave Martin <dave.martin@linaro.org>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      b5a63254
  11. 03 8月, 2010 3 次提交
    • A
      perf tools: Don't keep unreferenced maps when unmaps are detected · 0a1eae39
      Arnaldo Carvalho de Melo 提交于
      For a file with:
      
      [root@emilia linux-2.6-tip]# perf report -D -fi allmodconfig-j32.perf.data | grep events:
           TOTAL events:      36933
            MMAP events:       9056
            LOST events:          0
            COMM events:       1702
            EXIT events:       1887
        THROTTLE events:          8
      UNTHROTTLE events:          8
            FORK events:       1894
            READ events:          0
          SAMPLE events:      22378
            ATTR events:          0
      EVENT_TYPE events:          0
      TRACING_DATA events:          0
        BUILD_ID events:          0
      [root@emilia linux-2.6-tip]#
      
      Testing with valgrind and making perf_session__delete() a nop, so that
      we can notice how many maps were actually deleted due to not having any
      samples on it:
      
      ==== HEAP SUMMARY:
      
      Before:
      
      ==10339==     in use at exit: 8,909,997 bytes in 68,690 blocks
      ==10339==   total heap usage: 78,696 allocs, 10,007 frees, 11,925,853 bytes allocated
      
      After:
      
      ==10506==     in use at exit: 8,902,605 bytes in 68,606 blocks
      ==10506==   total heap usage: 78,696 allocs, 10,091 frees, 11,925,853 bytes allocated
      
      I.e. just 84 detected unmaps with no hits out of 9056 for this workload,
      not much, but in some other long running workload this may save more
      bytes.
      
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      LKML-Reference: <new-submission>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      0a1eae39
    • A
      perf session: Invalidate last_match when removing threads from rb_tree · 70597f21
      Arnaldo Carvalho de Melo 提交于
      If we receive two PERF_RECORD_EXIT for the same thread, we can end up
      reusing session->last_match and trying to remove the thread twice from
      the rb_tree, causing a segfault, so invalidade last_match in
      perf_session__remove_thread.
      
      Receiving two PERF_RECORD_EXIT for the same thread is a bug, but its a
      harmless one if we make the tool more robust, like this patch does.
      
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      LKML-Reference: <new-submission>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      70597f21
    • A
      perf session: Free the ref_reloc_sym memory at the right place · 076c6e45
      Arnaldo Carvalho de Melo 提交于
      Which is at perf_session__destroy_kernel_maps, counterpart to the
      perf_session__create_kernel_maps where the kmap structure is located, just
      after the vmlinux_maps.
      
      Make it also check if the kernel maps were actually created, which may not
      be the case if, for instance, perf_session__new can't complete due to
      permission problems in, for instance, a 'perf report' case, when a
      segfault will take place, that is how this was noticed.
      
      The problem was introduced in d65a458b, thus post .35.
      
      This also adds code to release guest machines as them are also created
      in perf_session__create_kernel_maps, so should be deleted on this newly
      introduced counterpart, perf_session__destroy_kernel_maps.
      
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      LKML-Reference: <new-submission>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      076c6e45
  12. 31 7月, 2010 2 次提交
    • A
      perf tools: Release session and symbol resources on exit · d65a458b
      Arnaldo Carvalho de Melo 提交于
      So that we reduce the noise when looking for leaks using tools such as
      valgrind.
      
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      LKML-Reference: <new-submission>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      d65a458b
    • A
      perf tools: Release thread resources on PERF_RECORD_EXIT · 591765fd
      Arnaldo Carvalho de Melo 提交于
      For long running sessions with many threads with short lifetimes the
      amount of memory that the buildid process takes is too much.
      
      Since we don't have hist_entries that may be pointing to them, we can
      just release the resources associated with each thread when the exit
      (PERF_RECORD_EXIT) event is received.
      
      For normal processing we need to annotate maps with hits, and thus
      hist_entries pointing to it and drop the ones that had none. Will be
      done in a followup patch.
      
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      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: Tom Zanussi <tzanussi@gmail.com>
      LKML-Reference: <new-submission>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      591765fd
  13. 30 7月, 2010 1 次提交
    • S
      perf probe: Rename common fields/functions from kprobe to probe. · 0e60836b
      Srikar Dronamraju 提交于
      As a precursor for perf to support uprobes, rename fields/functions
      that had kprobe in their name but can be shared across perf-kprobes
      and perf-uprobes to probe.
      
      Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Christoph Hellwig <hch@infradead.org>
      Cc: "Frank Ch. Eigler" <fche@redhat.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Jim Keniston <jkenisto@linux.vnet.ibm.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Mark Wielaard <mjw@redhat.com>
      Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
      Cc: Naren A Devaiah <naren.devaiah@in.ibm.com>
      Cc: Oleg Nesterov <oleg@redhat.com>
      Cc: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Randy Dunlap <rdunlap@xenotime.net>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      LKML-Reference: <20100729141351.GG21723@linux.vnet.ibm.com>
      Signed-off-by: NSrikar Dronamraju <srikar@linux.vnet.ibm.com>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      0e60836b