diff options
author | Adrian Hunter <adrian.hunter@intel.com> | 2015-04-30 10:37:26 -0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2015-05-04 18:49:42 -0400 |
commit | cd10b289520577a56c5d369b9a2e7bbee5698a4b (patch) | |
tree | bdfc63099fc74ec91d2040fac9411f26ae7a166a /tools/perf/builtin-inject.c | |
parent | 99fa298453495ee23801ab500a5fe0138c260edb (diff) |
perf tools: Hit all build ids when AUX area tracing
We need to include all buildids when a perf.data file contains AUX area
tracing data because we do not decode the trace for that purpose because
it would take too long.
Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Acked-by: Jiri Olsa <jolsa@kernel.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Namhyung Kim <namhyung@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1430404667-10593-4-git-send-email-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/builtin-inject.c')
-rw-r--r-- | tools/perf/builtin-inject.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tools/perf/builtin-inject.c b/tools/perf/builtin-inject.c index 6d4bbde066fd..cc905f1d3124 100644 --- a/tools/perf/builtin-inject.c +++ b/tools/perf/builtin-inject.c | |||
@@ -27,6 +27,7 @@ struct perf_inject { | |||
27 | struct perf_session *session; | 27 | struct perf_session *session; |
28 | bool build_ids; | 28 | bool build_ids; |
29 | bool sched_stat; | 29 | bool sched_stat; |
30 | bool have_auxtrace; | ||
30 | const char *input_name; | 31 | const char *input_name; |
31 | struct perf_data_file output; | 32 | struct perf_data_file output; |
32 | u64 bytes_written; | 33 | u64 bytes_written; |
@@ -122,6 +123,8 @@ static s64 perf_event__repipe_auxtrace(struct perf_tool *tool, | |||
122 | tool); | 123 | tool); |
123 | int ret; | 124 | int ret; |
124 | 125 | ||
126 | inject->have_auxtrace = true; | ||
127 | |||
125 | if (!inject->output.is_pipe) { | 128 | if (!inject->output.is_pipe) { |
126 | off_t offset; | 129 | off_t offset; |
127 | 130 | ||
@@ -508,9 +511,12 @@ static int __cmd_inject(struct perf_inject *inject) | |||
508 | ret = perf_session__process_events(session); | 511 | ret = perf_session__process_events(session); |
509 | 512 | ||
510 | if (!file_out->is_pipe) { | 513 | if (!file_out->is_pipe) { |
511 | if (inject->build_ids) | 514 | if (inject->build_ids) { |
512 | perf_header__set_feat(&session->header, | 515 | perf_header__set_feat(&session->header, |
513 | HEADER_BUILD_ID); | 516 | HEADER_BUILD_ID); |
517 | if (inject->have_auxtrace) | ||
518 | dsos__hit_all(session); | ||
519 | } | ||
514 | /* | 520 | /* |
515 | * The AUX areas have been removed and replaced with | 521 | * The AUX areas have been removed and replaced with |
516 | * synthesized hardware events, so clear the feature flag. | 522 | * synthesized hardware events, so clear the feature flag. |