summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/annotate.h
diff options
context:
space:
mode:
authorTaeung Song2017-07-20 21:28:53 +0200
committerArnaldo Carvalho de Melo2017-07-21 13:23:50 +0200
commitbab89f6aed7e745893e009014354d0caaf62acf7 (patch)
treef1229f13ff462f6235b19850ed2822ec93891429 /tools/perf/util/annotate.h
parentperf annotate: Rename 'sum' to 'nr_samples' in struct sym_hist (diff)
downloadkernel-qcow2-linux-bab89f6aed7e745893e009014354d0caaf62acf7.tar.gz
kernel-qcow2-linux-bab89f6aed7e745893e009014354d0caaf62acf7.tar.xz
kernel-qcow2-linux-bab89f6aed7e745893e009014354d0caaf62acf7.zip
perf hists: Pass perf_sample to __symbol__inc_addr_samples()
To pave the way to use perf_sample fields in the annotate code, storing sample->period in sym_hist->addr->period and its sum in sym_hist->period. Signed-off-by: Taeung Song <treeze.taeung@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Link: http://lkml.kernel.org/r/1500500215-16646-1-git-send-email-treeze.taeung@gmail.com [ split and adjusted from a larger patch ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/annotate.h')
-rw-r--r--tools/perf/util/annotate.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/perf/util/annotate.h b/tools/perf/util/annotate.h
index e8c246ec53df..720f18195046 100644
--- a/tools/perf/util/annotate.h
+++ b/tools/perf/util/annotate.h
@@ -154,13 +154,15 @@ static inline struct annotation *symbol__annotation(struct symbol *sym)
return (void *)sym - symbol_conf.priv_size;
}
-int addr_map_symbol__inc_samples(struct addr_map_symbol *ams, int evidx);
+int addr_map_symbol__inc_samples(struct addr_map_symbol *ams, struct perf_sample *sample,
+ int evidx);
int addr_map_symbol__account_cycles(struct addr_map_symbol *ams,
struct addr_map_symbol *start,
unsigned cycles);
-int hist_entry__inc_addr_samples(struct hist_entry *he, int evidx, u64 addr);
+int hist_entry__inc_addr_samples(struct hist_entry *he, struct perf_sample *sample,
+ int evidx, u64 addr);
int symbol__alloc_hist(struct symbol *sym);
void symbol__annotate_zero_histograms(struct symbol *sym);