1. 12 Jun, 2014 10 commits
    • Jiri Olsa's avatar
      perf tools: Add file size check and factor dso__data_read_offset · c3fbd2a6
      Jiri Olsa authored
      Adding file size check, because the lseek will succeed for
      any offset behind file size and thus succeed when it was
      expected to fail.
      
      Factoring the code to check the offset against file size
      earlier in the flow.
      Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1401892622-30848-8-git-send-email-jolsa@kernel.orgSigned-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      c3fbd2a6
    • Jiri Olsa's avatar
      perf tools: Cache dso data file descriptor · c6580451
      Jiri Olsa authored
      Caching dso data file descriptors to avoid expensive re-opens
      especially during DWARF unwind.
      
      We keep dsos data file descriptors open until their count reaches
      the half of the current fd open limit (RLIMIT_NOFILE). In this case
      we close file descriptor of the first opened dso object.
      
      We've got overall speedup (~27% for my workload) of report:
       'perf report --stdio -i perf-test.data' (3 runs)
        (perf-test.data size was around 12GB)
      
        current code:
         545,640,944,228      cycles                     ( +-  0.53% )
         785,255,798,320      instructions               ( +-  0.03% )
      
           366.340910010 seconds time elapsed            ( +-  3.65% )
      
        after change:
         435,895,036,114      cycles                     ( +-  0.26% )
         636,790,271,176      instructions               ( +-  0.04% )
      
           266.481463387 seconds time elapsed            ( +-  0.13% )
      Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1401892622-30848-7-git-send-email-jolsa@kernel.orgSigned-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      c6580451
    • Jiri Olsa's avatar
      perf tools: Add global count of opened dso objects · bda6ee4a
      Jiri Olsa authored
      Adding global count of opened dso objects so we could
      properly limit the number of opened dso data file
      descriptors.
      Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1401892622-30848-6-git-send-email-jolsa@kernel.orgSigned-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      bda6ee4a
    • Jiri Olsa's avatar
      perf tools: Add global list of opened dso objects · eba5102d
      Jiri Olsa authored
      Adding global list of opened dso objects, so we can
      track them and use the list for caching dso data file
      descriptors.
      Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1401892622-30848-5-git-send-email-jolsa@kernel.orgSigned-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      eba5102d
    • Jiri Olsa's avatar
      perf tools: Add data_fd into dso object · 53fa8eaa
      Jiri Olsa authored
      Adding data_fd into dso object so we could handle caching
      of opened dso file data descriptors coming int next patches.
      
      Adding dso__data_close interface to keep the data_fd updated
      when the descriptor is closed.
      Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1401892622-30848-4-git-send-email-jolsa@kernel.orgSigned-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      53fa8eaa
    • Jiri Olsa's avatar
      perf tools: Separate dso data related variables · ca40e2af
      Jiri Olsa authored
      Add separated structure/namespace for data related
      variables. We are going to add mode of them, so this
      way they will be clearly separated.
      Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1401892622-30848-3-git-send-email-jolsa@kernel.orgSigned-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      ca40e2af
    • Jiri Olsa's avatar
      perf tools: Cache register accesses for unwind processing · 0c4e774f
      Jiri Olsa authored
      Caching registers value into an array. Got about 4% speed up
      of perf_reg_value function for report command processing
      dwarf unwind stacks.
      
      Output from report over 1.5 GB data with DWARF unwind stacks:
      (TODO fix perf diff)
      
        current code:
         5.84%     perf  perf                       [.] perf_reg_value
        change:
         1.94%     perf  perf                       [.] perf_reg_value
      
      And little bit of overall speed up:
      (perf stat -r 5 -e '{cycles,instructions}:u' ...)
      
        current code:
         310,298,611,754      cycles                     ( +-  0.33% )
         439,669,689,341      instructions               ( +-  0.03% )
      
           188.656753166 seconds time elapsed            ( +-  0.82% )
      
        change:
         291,315,329,878      cycles                     ( +-  0.22% )
         391,763,485,304      instructions               ( +-  0.03%  )
      
           180.742249687 seconds time elapsed            ( +-  0.64% )
      Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1401892622-30848-2-git-send-email-jolsa@kernel.orgSigned-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      0c4e774f
    • Namhyung Kim's avatar
      perf record: Fix to honor user freq/interval properly · 17314e23
      Namhyung Kim authored
      When configuring event perf checked a wrong condition that user
      specified both of freq (-F) and period (-c) or the event has no
      default value.  This worked because most of events don't have default
      value and only tracepoint events have default of 1 (and it's not
      desirable to change it for those events).
      
      However, Andi's downloadable event patch changes the situation so it
      cannot change the value for those events.  Fix it by allowing override
      the default value if user gives one of the options.
      
        $ perf record -a -e uops_retired.all -F 4000 sleep 1
        [ perf record: Woken up 1 times to write data ]
        [ perf record: Captured and wrote 0.325 MB perf.data (~14185 samples) ]
      
        $ perf evlist -F
        cpu/uops_retired.all/: sample_freq=4000
      Signed-off-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Andi Kleen <andi@firstfloor.org>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Link: http://lkml.kernel.org/r/1402292617-26278-1-git-send-email-namhyung@kernel.orgSigned-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      17314e23
    • Ingo Molnar's avatar
      Merge tag 'perf-core-for-mingo' of... · 7184062b
      Ingo Molnar authored
      Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core
      
      Pull perf/core improvements from Arnaldo Carvalho de Melo:
      
      User visible:
      
        * Improve 'perf probe' error messages, moving some diagnostic messages to
          only appear in --verbose mode and fixing up some error reporting related
          to variables and struct members. (Masami Hiramatsu)
      
        * Reflow 'perf timechart' man page. (Stanislav Fomichev)
      
      Developer stuff:
      
        * Be more precise when reporting missing libraries in a static tool build.
          (Arnaldo Carvalho de Melo)
      
        * Show error messages from the multiple make invoked from 'make build-test'.
          (Arnaldo Carvalho de Melo)
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      7184062b
    • Ingo Molnar's avatar
      Merge tag 'perf-core-for-mingo' of... · 94eb1531
      Ingo Molnar authored
      Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf into perf/core
      
      Pull perf/core improvements and fixes from Jiri Olsa:
      
        * Bitmask handling and plugin updates (Steven Rostedt)
      
        * Fix pipe check regression in attr event callback (Jiri Olsa)
      
        * Prettify the tags/TAGS/cscope targets output (Jiri Olsa)
      
        * Print array argument as string (Namhyung Kim)
      
        * Pass protection and flags bits through mmap2 interface (Peter Zijlstra)
      
        * Update perf tool mmap2 interface with protection and flag bits (Don Zickus)
      
        * Re-enable mmap interface (Don Zickus)
      
        * Add mem-mode documentation to report command (Don Zickus)
      
        * Add sort on dcacheline (Don Zickus)
      Signed-off-by: default avatarJiri Olsa <jolsa@kernel.org>
      Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
      94eb1531
  2. 10 Jun, 2014 2 commits
  3. 09 Jun, 2014 15 commits
  4. 07 Jun, 2014 4 commits
  5. 06 Jun, 2014 3 commits
  6. 05 Jun, 2014 6 commits