Re: [GIT PULL 00/46] perf/core fixes and improvements

2018-06-06 Thread Ingo Molnar


* Arnaldo Carvalho de Melo  wrote:

> From: Arnaldo Carvalho de Melo 
> 
> Hi Ingo,
> 
>   Please consider pulling,
> 
> - Arnaldo
> 
> Test results at the end of this message, as usual.
> 
> The following changes since commit 7869e5889477e4e32e4024d665431b35e8b7b693:
> 
>   Merge remote-tracking branch 'tip/perf/urgent' into perf/core (2018-06-04 
> 10:28:20 -0300)
> 
> are available in the Git repository at:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git 
> tags/perf-core-for-mingo-4.18-20180605
> 
> for you to fetch changes up to 03ac4e71cd120d2c3411d106d00d266114575f74:
> 
>   perf intel-pt: Fix "Unexpected indirect branch" error (2018-06-05 12:28:52 
> -0300)
> 
> 
> perf/core improvements and fixes:
> 
> perf stat:
> 
> . Display user and system time for workload targets (Jiri Olsa)
> 
> perf record:
> 
> . Enable arbitrary event names thru name= modifier (Alexey Budankov)
> 
> PowerPC:
> 
> . Add a python script for hypervisor call statistics (Ravi Bangoria)
> 
> Intel PT: (Adrian Hunter)
> 
> . Fix sync_switch INTEL_PT_SS_NOT_TRACING
> 
> . Fix decoding to accept CBR between FUP and corresponding TIP
> 
> . Fix MTC timing after overflow
> 
> . Fix "Unexpected indirect branch" error
> 
> perf test:
> 
> . record+probe_libc_inet_pton:
> 
>   .  To get the symbol table for dynamic
>  shared objects on ubuntu we need to pass the -D/--dynamic command line
>  option, unlike with the fedora distros (Arnaldo Carvalho de Melo)
> 
> . code-reading:
> 
>   . Fix perf_env setup for PTI entry trampolines (Adrian Hunter)
> 
> . kmod-path:
> 
>   . Add tests for vdso32 and vdsox32 (Adrian Hunter)
> 
> . Use header file util/debug.h (Thomas Richter)
> 
> perf annotate:
> 
> . Make the various UI backends (stdio, TUI, gtk) use more consistently
>   structs with annotation options as specified by the user (Arnaldo Carvalho 
> de Melo)
> 
> . Move annotation specific knobs from the symbol_conf global kitchen
>   sink to the annotation option structs (Arnaldo Carvalho de Melo)
> 
> Core:
> 
> . Fix misleading error for some unparsable events mentioning PMUs when
>   those are not involved in the problem (Jiri Olsa)
> 
> - Fix symbol and object code resolution for vdso32 and vdsox32 (Adrian Hunter)
> 
> . No need to check for null when passing pointers to foo__get() style
>   refcount grabbing helpers, just like in the kernel and with free(),
>   its safe to pass a NULL pointer to avoid having to check it before
>   each and every foo__get() call (Arnaldo Carvalho de Melo)
> 
> . Remove some dead code (quote.[ch]) (Arnaldo Carvalho de Melo)
> 
> . Remove some needless globals, making them local (Arnaldo Carvalho de Melo)
> 
> . Reduce usage of symbol_conf.use_callchain, using other means of
>   finding out if callchains are in use or available for specific events,
>   as we evolved this codebase to allow requesting callchains for just
>   a subset of the monitored events. In time it will help polish
>   recording and showing mixed sets accross the various tools:
> 
> perf record -e 
> cycles/call-graph=fp/,cache-misses/call-graph=dwarf/,instructions
> 
>   (Arnaldo Carvalho de Melo)
> 
> . Consider PTI entry trampolines in map__rip_2objdump() (Adrian Hunter)
> 
> Signed-off-by: Arnaldo Carvalho de Melo 
> 
> 
> Adrian Hunter (8):
>   perf tests kmod-path: Add tests for vdso32 and vdsox32
>   perf tools: Fix symbol and object code resolution for vdso32 and vdsox32
>   perf test code-reading: Fix perf_env setup for PTI entry trampolines
>   perf map: Consider PTI entry trampolines in rip_2objdump()
>   perf intel-pt: Fix sync_switch INTEL_PT_SS_NOT_TRACING
>   perf intel-pt: Fix decoding to accept CBR between FUP and corresponding 
> TIP
>   perf intel-pt: Fix MTC timing after overflow
>   perf intel-pt: Fix "Unexpected indirect branch" error
> 
> Alexey Budankov (1):
>   perf record: Enable arbitrary event names thru name= modifier
> 
> Arnaldo Carvalho de Melo (33):
>   perf tools: Remove dead quote.[ch] code
>   perf probe: Use return of map__get() to make code more compact
>   perf cgroup: Make evlist__find_cgroup() more compact
>   perf tools: No need to check if the argument to __get() function is NULL
>   perf annotate: Pass perf_evsel instead of just evsel->idx
>   perf annotate: __symbol__acount_cycles doesn't need notes
>   perf annotate: Split allocation of annotated_source struct
>   perf annotate: Introduce constructor/destructor for annotated_source
>   perf annotate: Introduce annotated_source__alloc_histograms
>   perf annotate: __symbol__inc_addr_samples() needs just annotated_source
>   perf annotate: Introduce symbol__hists()
>   perf annotate: Introduce symbol__cycle_hists()
>   perf annotate: Stop using symbol_conf.nr_events global in 
> 

Re: [GIT PULL 00/46] perf/core fixes and improvements

2018-06-06 Thread Ingo Molnar


* Arnaldo Carvalho de Melo  wrote:

> From: Arnaldo Carvalho de Melo 
> 
> Hi Ingo,
> 
>   Please consider pulling,
> 
> - Arnaldo
> 
> Test results at the end of this message, as usual.
> 
> The following changes since commit 7869e5889477e4e32e4024d665431b35e8b7b693:
> 
>   Merge remote-tracking branch 'tip/perf/urgent' into perf/core (2018-06-04 
> 10:28:20 -0300)
> 
> are available in the Git repository at:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git 
> tags/perf-core-for-mingo-4.18-20180605
> 
> for you to fetch changes up to 03ac4e71cd120d2c3411d106d00d266114575f74:
> 
>   perf intel-pt: Fix "Unexpected indirect branch" error (2018-06-05 12:28:52 
> -0300)
> 
> 
> perf/core improvements and fixes:
> 
> perf stat:
> 
> . Display user and system time for workload targets (Jiri Olsa)
> 
> perf record:
> 
> . Enable arbitrary event names thru name= modifier (Alexey Budankov)
> 
> PowerPC:
> 
> . Add a python script for hypervisor call statistics (Ravi Bangoria)
> 
> Intel PT: (Adrian Hunter)
> 
> . Fix sync_switch INTEL_PT_SS_NOT_TRACING
> 
> . Fix decoding to accept CBR between FUP and corresponding TIP
> 
> . Fix MTC timing after overflow
> 
> . Fix "Unexpected indirect branch" error
> 
> perf test:
> 
> . record+probe_libc_inet_pton:
> 
>   .  To get the symbol table for dynamic
>  shared objects on ubuntu we need to pass the -D/--dynamic command line
>  option, unlike with the fedora distros (Arnaldo Carvalho de Melo)
> 
> . code-reading:
> 
>   . Fix perf_env setup for PTI entry trampolines (Adrian Hunter)
> 
> . kmod-path:
> 
>   . Add tests for vdso32 and vdsox32 (Adrian Hunter)
> 
> . Use header file util/debug.h (Thomas Richter)
> 
> perf annotate:
> 
> . Make the various UI backends (stdio, TUI, gtk) use more consistently
>   structs with annotation options as specified by the user (Arnaldo Carvalho 
> de Melo)
> 
> . Move annotation specific knobs from the symbol_conf global kitchen
>   sink to the annotation option structs (Arnaldo Carvalho de Melo)
> 
> Core:
> 
> . Fix misleading error for some unparsable events mentioning PMUs when
>   those are not involved in the problem (Jiri Olsa)
> 
> - Fix symbol and object code resolution for vdso32 and vdsox32 (Adrian Hunter)
> 
> . No need to check for null when passing pointers to foo__get() style
>   refcount grabbing helpers, just like in the kernel and with free(),
>   its safe to pass a NULL pointer to avoid having to check it before
>   each and every foo__get() call (Arnaldo Carvalho de Melo)
> 
> . Remove some dead code (quote.[ch]) (Arnaldo Carvalho de Melo)
> 
> . Remove some needless globals, making them local (Arnaldo Carvalho de Melo)
> 
> . Reduce usage of symbol_conf.use_callchain, using other means of
>   finding out if callchains are in use or available for specific events,
>   as we evolved this codebase to allow requesting callchains for just
>   a subset of the monitored events. In time it will help polish
>   recording and showing mixed sets accross the various tools:
> 
> perf record -e 
> cycles/call-graph=fp/,cache-misses/call-graph=dwarf/,instructions
> 
>   (Arnaldo Carvalho de Melo)
> 
> . Consider PTI entry trampolines in map__rip_2objdump() (Adrian Hunter)
> 
> Signed-off-by: Arnaldo Carvalho de Melo 
> 
> 
> Adrian Hunter (8):
>   perf tests kmod-path: Add tests for vdso32 and vdsox32
>   perf tools: Fix symbol and object code resolution for vdso32 and vdsox32
>   perf test code-reading: Fix perf_env setup for PTI entry trampolines
>   perf map: Consider PTI entry trampolines in rip_2objdump()
>   perf intel-pt: Fix sync_switch INTEL_PT_SS_NOT_TRACING
>   perf intel-pt: Fix decoding to accept CBR between FUP and corresponding 
> TIP
>   perf intel-pt: Fix MTC timing after overflow
>   perf intel-pt: Fix "Unexpected indirect branch" error
> 
> Alexey Budankov (1):
>   perf record: Enable arbitrary event names thru name= modifier
> 
> Arnaldo Carvalho de Melo (33):
>   perf tools: Remove dead quote.[ch] code
>   perf probe: Use return of map__get() to make code more compact
>   perf cgroup: Make evlist__find_cgroup() more compact
>   perf tools: No need to check if the argument to __get() function is NULL
>   perf annotate: Pass perf_evsel instead of just evsel->idx
>   perf annotate: __symbol__acount_cycles doesn't need notes
>   perf annotate: Split allocation of annotated_source struct
>   perf annotate: Introduce constructor/destructor for annotated_source
>   perf annotate: Introduce annotated_source__alloc_histograms
>   perf annotate: __symbol__inc_addr_samples() needs just annotated_source
>   perf annotate: Introduce symbol__hists()
>   perf annotate: Introduce symbol__cycle_hists()
>   perf annotate: Stop using symbol_conf.nr_events global in 
> 

[GIT PULL 00/46] perf/core fixes and improvements

2018-06-05 Thread Arnaldo Carvalho de Melo
From: Arnaldo Carvalho de Melo 

Hi Ingo,

Please consider pulling,

- Arnaldo

Test results at the end of this message, as usual.

The following changes since commit 7869e5889477e4e32e4024d665431b35e8b7b693:

  Merge remote-tracking branch 'tip/perf/urgent' into perf/core (2018-06-04 
10:28:20 -0300)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git 
tags/perf-core-for-mingo-4.18-20180605

for you to fetch changes up to 03ac4e71cd120d2c3411d106d00d266114575f74:

  perf intel-pt: Fix "Unexpected indirect branch" error (2018-06-05 12:28:52 
-0300)


perf/core improvements and fixes:

perf stat:

. Display user and system time for workload targets (Jiri Olsa)

perf record:

. Enable arbitrary event names thru name= modifier (Alexey Budankov)

PowerPC:

. Add a python script for hypervisor call statistics (Ravi Bangoria)

Intel PT: (Adrian Hunter)

. Fix sync_switch INTEL_PT_SS_NOT_TRACING

. Fix decoding to accept CBR between FUP and corresponding TIP

. Fix MTC timing after overflow

. Fix "Unexpected indirect branch" error

perf test:

. record+probe_libc_inet_pton:

  .  To get the symbol table for dynamic
 shared objects on ubuntu we need to pass the -D/--dynamic command line
 option, unlike with the fedora distros (Arnaldo Carvalho de Melo)

. code-reading:

  . Fix perf_env setup for PTI entry trampolines (Adrian Hunter)

. kmod-path:

  . Add tests for vdso32 and vdsox32 (Adrian Hunter)

. Use header file util/debug.h (Thomas Richter)

perf annotate:

. Make the various UI backends (stdio, TUI, gtk) use more consistently
  structs with annotation options as specified by the user (Arnaldo Carvalho de 
Melo)

. Move annotation specific knobs from the symbol_conf global kitchen
  sink to the annotation option structs (Arnaldo Carvalho de Melo)

Core:

. Fix misleading error for some unparsable events mentioning PMUs when
  those are not involved in the problem (Jiri Olsa)

- Fix symbol and object code resolution for vdso32 and vdsox32 (Adrian Hunter)

. No need to check for null when passing pointers to foo__get() style
  refcount grabbing helpers, just like in the kernel and with free(),
  its safe to pass a NULL pointer to avoid having to check it before
  each and every foo__get() call (Arnaldo Carvalho de Melo)

. Remove some dead code (quote.[ch]) (Arnaldo Carvalho de Melo)

. Remove some needless globals, making them local (Arnaldo Carvalho de Melo)

. Reduce usage of symbol_conf.use_callchain, using other means of
  finding out if callchains are in use or available for specific events,
  as we evolved this codebase to allow requesting callchains for just
  a subset of the monitored events. In time it will help polish
  recording and showing mixed sets accross the various tools:

perf record -e 
cycles/call-graph=fp/,cache-misses/call-graph=dwarf/,instructions

  (Arnaldo Carvalho de Melo)

. Consider PTI entry trampolines in map__rip_2objdump() (Adrian Hunter)

Signed-off-by: Arnaldo Carvalho de Melo 


Adrian Hunter (8):
  perf tests kmod-path: Add tests for vdso32 and vdsox32
  perf tools: Fix symbol and object code resolution for vdso32 and vdsox32
  perf test code-reading: Fix perf_env setup for PTI entry trampolines
  perf map: Consider PTI entry trampolines in rip_2objdump()
  perf intel-pt: Fix sync_switch INTEL_PT_SS_NOT_TRACING
  perf intel-pt: Fix decoding to accept CBR between FUP and corresponding 
TIP
  perf intel-pt: Fix MTC timing after overflow
  perf intel-pt: Fix "Unexpected indirect branch" error

Alexey Budankov (1):
  perf record: Enable arbitrary event names thru name= modifier

Arnaldo Carvalho de Melo (33):
  perf tools: Remove dead quote.[ch] code
  perf probe: Use return of map__get() to make code more compact
  perf cgroup: Make evlist__find_cgroup() more compact
  perf tools: No need to check if the argument to __get() function is NULL
  perf annotate: Pass perf_evsel instead of just evsel->idx
  perf annotate: __symbol__acount_cycles doesn't need notes
  perf annotate: Split allocation of annotated_source struct
  perf annotate: Introduce constructor/destructor for annotated_source
  perf annotate: Introduce annotated_source__alloc_histograms
  perf annotate: __symbol__inc_addr_samples() needs just annotated_source
  perf annotate: Introduce symbol__hists()
  perf annotate: Introduce symbol__cycle_hists()
  perf annotate: Stop using symbol_conf.nr_events global in symbol__hists()
  perf annotate: Replace symbol__alloc_hists() with symbol__hists()
  perf tools: Ditch the symbol_conf.nr_events global
  perf annotate: Add comment about annotated_src->nr_histograms
  perf annotate stdio: Use annotation_options consistently
  perf srcline: Introduce map__srcline() to 

[GIT PULL 00/46] perf/core fixes and improvements

2018-06-05 Thread Arnaldo Carvalho de Melo
From: Arnaldo Carvalho de Melo 

Hi Ingo,

Please consider pulling,

- Arnaldo

Test results at the end of this message, as usual.

The following changes since commit 7869e5889477e4e32e4024d665431b35e8b7b693:

  Merge remote-tracking branch 'tip/perf/urgent' into perf/core (2018-06-04 
10:28:20 -0300)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git 
tags/perf-core-for-mingo-4.18-20180605

for you to fetch changes up to 03ac4e71cd120d2c3411d106d00d266114575f74:

  perf intel-pt: Fix "Unexpected indirect branch" error (2018-06-05 12:28:52 
-0300)


perf/core improvements and fixes:

perf stat:

. Display user and system time for workload targets (Jiri Olsa)

perf record:

. Enable arbitrary event names thru name= modifier (Alexey Budankov)

PowerPC:

. Add a python script for hypervisor call statistics (Ravi Bangoria)

Intel PT: (Adrian Hunter)

. Fix sync_switch INTEL_PT_SS_NOT_TRACING

. Fix decoding to accept CBR between FUP and corresponding TIP

. Fix MTC timing after overflow

. Fix "Unexpected indirect branch" error

perf test:

. record+probe_libc_inet_pton:

  .  To get the symbol table for dynamic
 shared objects on ubuntu we need to pass the -D/--dynamic command line
 option, unlike with the fedora distros (Arnaldo Carvalho de Melo)

. code-reading:

  . Fix perf_env setup for PTI entry trampolines (Adrian Hunter)

. kmod-path:

  . Add tests for vdso32 and vdsox32 (Adrian Hunter)

. Use header file util/debug.h (Thomas Richter)

perf annotate:

. Make the various UI backends (stdio, TUI, gtk) use more consistently
  structs with annotation options as specified by the user (Arnaldo Carvalho de 
Melo)

. Move annotation specific knobs from the symbol_conf global kitchen
  sink to the annotation option structs (Arnaldo Carvalho de Melo)

Core:

. Fix misleading error for some unparsable events mentioning PMUs when
  those are not involved in the problem (Jiri Olsa)

- Fix symbol and object code resolution for vdso32 and vdsox32 (Adrian Hunter)

. No need to check for null when passing pointers to foo__get() style
  refcount grabbing helpers, just like in the kernel and with free(),
  its safe to pass a NULL pointer to avoid having to check it before
  each and every foo__get() call (Arnaldo Carvalho de Melo)

. Remove some dead code (quote.[ch]) (Arnaldo Carvalho de Melo)

. Remove some needless globals, making them local (Arnaldo Carvalho de Melo)

. Reduce usage of symbol_conf.use_callchain, using other means of
  finding out if callchains are in use or available for specific events,
  as we evolved this codebase to allow requesting callchains for just
  a subset of the monitored events. In time it will help polish
  recording and showing mixed sets accross the various tools:

perf record -e 
cycles/call-graph=fp/,cache-misses/call-graph=dwarf/,instructions

  (Arnaldo Carvalho de Melo)

. Consider PTI entry trampolines in map__rip_2objdump() (Adrian Hunter)

Signed-off-by: Arnaldo Carvalho de Melo 


Adrian Hunter (8):
  perf tests kmod-path: Add tests for vdso32 and vdsox32
  perf tools: Fix symbol and object code resolution for vdso32 and vdsox32
  perf test code-reading: Fix perf_env setup for PTI entry trampolines
  perf map: Consider PTI entry trampolines in rip_2objdump()
  perf intel-pt: Fix sync_switch INTEL_PT_SS_NOT_TRACING
  perf intel-pt: Fix decoding to accept CBR between FUP and corresponding 
TIP
  perf intel-pt: Fix MTC timing after overflow
  perf intel-pt: Fix "Unexpected indirect branch" error

Alexey Budankov (1):
  perf record: Enable arbitrary event names thru name= modifier

Arnaldo Carvalho de Melo (33):
  perf tools: Remove dead quote.[ch] code
  perf probe: Use return of map__get() to make code more compact
  perf cgroup: Make evlist__find_cgroup() more compact
  perf tools: No need to check if the argument to __get() function is NULL
  perf annotate: Pass perf_evsel instead of just evsel->idx
  perf annotate: __symbol__acount_cycles doesn't need notes
  perf annotate: Split allocation of annotated_source struct
  perf annotate: Introduce constructor/destructor for annotated_source
  perf annotate: Introduce annotated_source__alloc_histograms
  perf annotate: __symbol__inc_addr_samples() needs just annotated_source
  perf annotate: Introduce symbol__hists()
  perf annotate: Introduce symbol__cycle_hists()
  perf annotate: Stop using symbol_conf.nr_events global in symbol__hists()
  perf annotate: Replace symbol__alloc_hists() with symbol__hists()
  perf tools: Ditch the symbol_conf.nr_events global
  perf annotate: Add comment about annotated_src->nr_histograms
  perf annotate stdio: Use annotation_options consistently
  perf srcline: Introduce map__srcline() to