aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf')
-rw-r--r--tools/perf/util/hist.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/perf/util/hist.c b/tools/perf/util/hist.c
index 3197f3f50018..02476cb3167d 100644
--- a/tools/perf/util/hist.c
+++ b/tools/perf/util/hist.c
@@ -223,7 +223,7 @@ static struct hist_entry *hist_entry__new(struct hist_entry *template)
223 223
224 if (he != NULL) { 224 if (he != NULL) {
225 *he = *template; 225 *he = *template;
226 he->stat.nr_events = 1; 226
227 if (he->ms.map) 227 if (he->ms.map)
228 he->ms.map->referenced = true; 228 he->ms.map->referenced = true;
229 if (symbol_conf.use_callchain) 229 if (symbol_conf.use_callchain)
@@ -323,6 +323,7 @@ struct hist_entry *__hists__add_branch_entry(struct hists *self,
323 .level = al->level, 323 .level = al->level,
324 .stat = { 324 .stat = {
325 .period = period, 325 .period = period,
326 .nr_events = 1,
326 }, 327 },
327 .parent = sym_parent, 328 .parent = sym_parent,
328 .filtered = symbol__parent_filter(sym_parent), 329 .filtered = symbol__parent_filter(sym_parent),
@@ -348,6 +349,7 @@ struct hist_entry *__hists__add_entry(struct hists *self,
348 .level = al->level, 349 .level = al->level,
349 .stat = { 350 .stat = {
350 .period = period, 351 .period = period,
352 .nr_events = 1,
351 }, 353 },
352 .parent = sym_parent, 354 .parent = sym_parent,
353 .filtered = symbol__parent_filter(sym_parent), 355 .filtered = symbol__parent_filter(sym_parent),