1. 02 3月, 2021 2 次提交
  2. 01 12月, 2020 2 次提交
  3. 23 6月, 2020 1 次提交
  4. 28 5月, 2020 2 次提交
    • A
      perf record: Respect --no-switch-events · 16b4b4e1
      Adrian Hunter 提交于
      Context switch events are added automatically by Intel PT and Coresight.
      
      Make it possible to suppress them. That is useful for tracing the
      scheduler without the disturbance that the switch event processing
      creates.
      
      Example:
      
        Prerequisites:
      
          $ which perf
          ~/bin/perf
          $ sudo setcap "cap_sys_rawio,cap_sys_admin,cap_sys_ptrace,cap_syslog,cap_ipc_lock=ep" ~/bin/perf
          $ sudo chmod +r /proc/kcore
      
        Before:
      
          $ perf record --no-switch-events --kcore -a -e intel_pt//k -- sleep 0.001
          [ perf record: Woken up 1 times to write data ]
          [ perf record: Captured and wrote 0.938 MB perf.data ]
          $ perf script -D | grep PERF_RECORD_SWITCH | wc -l
          572
      
        After:
      
          $ perf record --no-switch-events --kcore -a -e intel_pt//k -- sleep 0.001
          Warning:
          Intel Processor Trace decoding will not be possible except for kernel tracing!
          [ perf record: Woken up 1 times to write data ]
          [ perf record: Captured and wrote 0.838 MB perf.data ]
          $ perf script -D | grep PERF_RECORD_SWITCH | wc -l
          0
      
          $ sudo chmod go-r /proc/kcore
          $ sudo setcap -r ~/bin/perf
      Signed-off-by: NAdrian Hunter <adrian.hunter@intel.com>
      Tested-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Andi Kleen <ak@linux.intel.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mathieu Poirier <mathieu.poirier@linaro.org>
      Link: http://lore.kernel.org/lkml/20200528120859.21604-1-adrian.hunter@intel.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      16b4b4e1
    • A
      perf evsel: Rename *perf_evsel__get_config_term() & friends to evsel__env() · 35ac0cad
      Arnaldo Carvalho de Melo 提交于
      As it is a 'struct evsel' method, not part of tools/lib/perf/, aka
      libperf, to whom the perf_ prefix belongs.
      
      Cc: Adrian Hunter <adrian.hunter@intel.com>
      Cc: Jiri Olsa <jolsa@kernel.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      35ac0cad
  5. 06 5月, 2020 3 次提交
  6. 18 2月, 2020 2 次提交
  7. 30 1月, 2020 1 次提交
    • L
      perf parse: Refactor 'struct perf_evsel_config_term' · e884602b
      Leo Yan 提交于
      The struct perf_evsel_config_term::val is a union which contains fields
      'callgraph', 'drv_cfg' and 'branch' as string pointers.  This leads to
      the complex code logic for handling every type's string separately, and
      it's hard to release string as a general way.
      
      This patch refactors the structure to add a common field 'str' in the
      'val' union as string pointer and remove the other three fields
      'callgraph', 'drv_cfg' and 'branch'.  Without passing field name, the
      patch simplifies the string handling with macro ADD_CONFIG_TERM_STR()
      for string pointer assignment.
      
      This patch fixes multiple warnings of line over 80 characters detected
      by checkpatch tool.
      Signed-off-by: NLeo Yan <leo.yan@linaro.org>
      Reviewed-by: NAndi Kleen <ak@linux.intel.com>
      Acked-by: NJiri Olsa <jolsa@kernel.org>
      Cc: Adrian Hunter <adrian.hunter@intel.com>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Ian Rogers <irogers@google.com>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Mathieu Poirier <mathieu.poirier@linaro.org>
      Cc: Mike Leach <mike.leach@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Suzuki Poulouse <suzuki.poulose@arm.com>
      Cc: linux-arm-kernel@lists.infradead.org
      Link: http://lore.kernel.org/lkml/20200117055251.24058-1-leo.yan@linaro.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      e884602b
  8. 26 9月, 2019 1 次提交
  9. 25 9月, 2019 3 次提交
  10. 20 9月, 2019 1 次提交
  11. 01 9月, 2019 3 次提交
  12. 30 8月, 2019 1 次提交
  13. 29 8月, 2019 2 次提交
  14. 26 8月, 2019 1 次提交
  15. 22 8月, 2019 2 次提交
  16. 30 7月, 2019 9 次提交
  17. 09 7月, 2019 1 次提交
  18. 26 6月, 2019 1 次提交
  19. 18 6月, 2019 1 次提交
  20. 11 6月, 2019 1 次提交
    • M
      perf cs-etm: Properly set the value of 'old' and 'head' in snapshot mode · e45c48a9
      Mathieu Poirier 提交于
      This patch adds the necessary intelligence to properly compute the value
      of 'old' and 'head' when operating in snapshot mode.  That way we can
      get the latest information in the AUX buffer and be compatible with the
      generic AUX ring buffer mechanic.
      
      Tester notes:
      
      > Leo, have you had the chance to test/review this one? Suzuki?
      
      Sure.  I applied this patch on the perf/core branch (with latest
      commit 3e4fbf36c1e3 'perf augmented_raw_syscalls: Move reading
      filename to the loop') and passed testing with below steps:
      
        # perf record -e cs_etm/@tmc_etr0/ -S -m,64 --per-thread ./sort &
        [1] 19097
        Bubble sorting array of 30000 elements
      
        # kill -USR2 19097
        # kill -USR2 19097
        # kill -USR2 19097
        [ perf record: Woken up 4 times to write data ]
        [ perf record: Captured and wrote 0.753 MB perf.data ]
      Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org>
      Tested-by: NLeo Yan <leo.yan@linaro.org>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Suzuki Poulouse <suzuki.poulose@arm.com>
      Cc: linux-arm-kernel@lists.infradead.org
      Link: http://lkml.kernel.org/r/20190605161633.12245-1-mathieu.poirier@linaro.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      e45c48a9