1. 03 Apr, 2010 5 commits
  2. 02 Apr, 2010 12 commits
    • Arnaldo Carvalho de Melo's avatar
      perf tools: sort_dimension__add shouldn't die · 2aefa4f7
      Arnaldo Carvalho de Melo authored
      Propagate error instead.
      
      LKML-Reference: <new-submission>
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      2aefa4f7
    • Arnaldo Carvalho de Melo's avatar
      perf session: Remove one more exit() call from library code · ad5b217b
      Arnaldo Carvalho de Melo authored
      Return NULL instead and make the caller propagate the error.
      
      LKML-Reference: <new-submission>
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      ad5b217b
    • Arnaldo Carvalho de Melo's avatar
      perf hist: Only allocate callchain_node if processing callchains · b9fb9304
      Arnaldo Carvalho de Melo authored
      The struct callchain_node size is 120 bytes, that are never used when
      there are no callchains or '-g none' is specified, so conditionally
      allocate it, reducing sizeof(struct hist_entry) from 210 bytes to only
      96, greatly speeding the non-callchain processing.
      
      LKML-Reference: <new-submission>
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      b9fb9304
    • Arnaldo Carvalho de Melo's avatar
      perf kmem: Fixup the symbol address before using it · 71cf8b8f
      Arnaldo Carvalho de Melo authored
      We get absolute addresses in the events, but relative ones from the
      symbol subsystem, so calculate the absolute address by asking for the
      map where the symbol was found, that has the place where the DSO was
      actually loaded.
      
      For the core kernel this poses no problems if the kernel is not
      relocated by things like kexec, or if we use /proc/kallsyms, but for
      modules we were getting really large, negative offsets.
      
      LKML-Reference: <new-submission>
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Li Zefan <lizf@cn.fujitsu.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      71cf8b8f
    • Arnaldo Carvalho de Melo's avatar
      perf kmem: Resolve kernel symbols again · e727ca73
      Arnaldo Carvalho de Melo authored
      Due to the assumption in perf_session__new that the kernel maps would be
      created using the fake PERF_RECORD_MMAP event in a perf.data file 'perf
      kmem --stat caller', that doesn't have such event, ends up not being
      able to resolve the kernel addresses.
      
      Fix it by calling perf_session__create_kernel_maps() in __cmd_kmem().
      
      LKML-Reference: <new-submission>
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      e727ca73
    • Arnaldo Carvalho de Melo's avatar
      perf hist: Replace ->print() routines by ->snprintf() equivalents · a4e3b956
      Arnaldo Carvalho de Melo authored
      Then hist_entry__fprintf will just us the newly introduced
      hist_entry__snprintf, add the newline and fprintf it to the supplied
      FILE descriptor.
      
      This allows us to remove the use_browser checking in the color_printf
      routines, that now got color_snprintf variants too.
      
      The newt TUI browser (and other GUIs that may come in the future) don't
      have to worry about stdio specific stuff in the strings they get from
      the se->snprintf routines and instead use whatever means to do the
      equivalent.
      
      Also the newt TUI browser don't have to use the fmemopen() hack, instead
      it can use the se->snprintf routines directly. For now tho use the
      hist_entry__snprintf routine to reduce the patch size.
      
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      a4e3b956
    • Arnaldo Carvalho de Melo's avatar
      perf record: Add a fallback to the reference relocation symbol · 70162138
      Arnaldo Carvalho de Melo authored
      Usually "_text" is enough, but I received reports that its not always
      available, so fallback to "_stext" for the symbol we use to check if we
      need to apply any relocation to all the symbols in the kernel symtab,
      for when, for instance, kexec is being used.
      Reported-by: default avatarDarren Hart <dvhltc@us.ibm.com>
      Cc: Darren Hart <dvhltc@us.ibm.com>
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      70162138
    • Arnaldo Carvalho de Melo's avatar
      perf tools: Allow specifying O= to build files in a separate directory · c29ede61
      Arnaldo Carvalho de Melo authored
      Avoiding polluting the source tree with build files.
      Reported-by: default avatarSteven Rostedt <rostedt@goodmis.org>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      c29ede61
    • Arnaldo Carvalho de Melo's avatar
      perf tools: Use -o $(BITBUCKET) in one more case · 8b2c551f
      Arnaldo Carvalho de Melo authored
      As described in 1703f2c3 some gcc versions has issues using /dev/null, so
      use the mechanism used elsewhere.
      
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      8b2c551f
    • Arnaldo Carvalho de Melo's avatar
      perf report: Add progress bars · 5f4d3f88
      Arnaldo Carvalho de Melo authored
      For when we are processing the events and inserting the entries in the
      browser.
      
      Experimentation here: naming "ui_something" we may be treading into
      creating a TUI/GUI set of routines that can then be implemented in terms
      of multiple backends.
      
      Also the time it takes for adding things to the "browser" takes, visually
      (I guess I should do some profiling here ;-) ), more time than for
      processing the events...
      
      That means we probably need to create a custom hist_entry browser, so
      that we reuse the structures we have in place instead of duplicating
      them in newt.
      
      But progress was made and at least we can see something while long files
      are being loaded, that must be one of UI 101 bullet points :-)
      
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      5f4d3f88
    • Arnaldo Carvalho de Melo's avatar
      perf symbols: map_groups__find_symbol must return the map too · 7e5e1b14
      Arnaldo Carvalho de Melo authored
      Tools need to know from which map in the map_group a symbol was resolved
      to, so that, for isntance, we can annotate kernel modules symbols by
      getting its precise name, etc.
      
      Also add the _by_name variants for completeness.
      
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      7e5e1b14
    • Arnaldo Carvalho de Melo's avatar
      perf symbols: Move more map_groups methods to map.c · c6e718ff
      Arnaldo Carvalho de Melo authored
      While writing a standalone test app that uses the symbol system to
      find kernel space symbols I noticed these also need to be moved.
      
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      c6e718ff
  3. 26 Mar, 2010 16 commits
  4. 23 Mar, 2010 1 commit
  5. 22 Mar, 2010 6 commits