perf report: Also do default setup for synthesized branch stacks
authorAdrian Hunter <adrian.hunter@intel.com>
Fri, 25 Sep 2015 13:15:41 +0000 (16:15 +0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 28 Sep 2015 19:54:45 +0000 (16:54 -0300)
The 'perf report' tool will default to displaying branch stacks (-b
option) if they are present.  Make that also happen for synthesized
branch stacks.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Link: http://lkml.kernel.org/r/1443186956-18718-11-git-send-email-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-report.c

index 7af35af5a5e58a90775fd5b3e94e2664609436a1..92f7c5a752081f73bf1d8a4048491347108d6418 100644 (file)
@@ -829,6 +829,9 @@ repeat:
        has_br_stack = perf_header__has_feat(&session->header,
                                             HEADER_BRANCH_STACK);
 
+       if (itrace_synth_opts.last_branch)
+               has_br_stack = true;
+
        /*
         * Branch mode is a tristate:
         * -1 means default, so decide based on the file having branch data.