lkml.org 
[lkml]   [2018]   [Sep]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH v4 6/8] perf, tools, script: Make itrace script default to all calls
On Mon, 3 Sep 2018 09:22:47 -0700
Andi Kleen <andi@firstfloor.org> wrote:

<snip>
> Fix ETM build failure
> ---
> diff --git a/tools/perf/util/cs-etm.c b/tools/perf/util/cs-etm.c
> index 2ae640257fdb..0296405f38b2 100644
> --- a/tools/perf/util/cs-etm.c
> +++ b/tools/perf/util/cs-etm.c
> @@ -1432,7 +1432,8 @@ int cs_etm__process_auxtrace_info(union perf_event *event,
> if (session->itrace_synth_opts && session->itrace_synth_opts->set) {
> etm->synth_opts = *session->itrace_synth_opts;
> } else {
> - itrace_synth_opts__set_default(&etm->synth_opts);
> + itrace_synth_opts__set_default(&etm->synth_opts,
> + etm->synth_opts->default_no_sample);

This still fails but with a different error:

CC util/cs-etm.o
util/cs-etm.c: In function ‘cs_etm__process_auxtrace_info’:
util/cs-etm.c:1436:20: error: invalid type argument of ‘->’ (have ‘struct itrace_synth_opts’)
etm->synth_opts->default_no_sample);
^~

I tried this diff, and it built:

diff --git a/tools/perf/util/cs-etm.c b/tools/perf/util/cs-etm.c
index 0296405f38b2..3b37d66dc533 100644
--- a/tools/perf/util/cs-etm.c
+++ b/tools/perf/util/cs-etm.c
@@ -1433,7 +1433,7 @@ int cs_etm__process_auxtrace_info(union perf_event *event,
etm->synth_opts = *session->itrace_synth_opts;
} else {
itrace_synth_opts__set_default(&etm->synth_opts,
- etm->synth_opts->default_no_sample);
+ session->itrace_synth_opts->default_no_sample);
etm->synth_opts.callchain = false;
}

So please incorporate it in this patch.
FYI, building-in cs-etm decoding into perf depends on
CONFIG_LIBOPENCSD. Debian has a package 'libopencsd' that provides
it. I don't know about other distros, but it's possible to build and
install the library from scratch:

https://github.com/Linaro/OpenCSD/

Thanks,

Kim

\
 
 \ /
  Last update: 2018-09-04 21:38    [W:0.060 / U:1.388 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site