Messages in this thread | | | Date | Tue, 26 May 2015 12:09:12 +0200 | From | Jiri Olsa <> | Subject | Re: [PATCH 04/10] perf, tools, report: Add processing for cycle histograms |
| |
On Sun, May 10, 2015 at 06:52:00AM -0700, Andi Kleen wrote:
SNIP
> mi = he->mem_info; > err = addr_map_symbol__inc_samples(&mi->daddr, evsel->idx); > diff --git a/tools/perf/util/hist.c b/tools/perf/util/hist.c > index 302fc05..cf6b48b 100644 > --- a/tools/perf/util/hist.c > +++ b/tools/perf/util/hist.c > @@ -1412,6 +1412,39 @@ int hists__link(struct hists *leader, struct hists *other) > return 0; > } > > +void hist__account_cycles(struct branch_stack *bs, struct addr_location *al, > + struct perf_sample *sample, bool nonstd_branch_mode) > +{ > + struct branch_info *bi; > + > + /* If we have branch cycles always annotate them. */ > + if (bs && bs->nr && bs->entries[0].flags.cycles) {
hum, so this is assuming that having cycles fort 1st entry means there'll be for the rest?
Also in that case why is there the '!= cycles' check within addr_map_symbol__account_cycles ?
jirka
| |