All of lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Ian Rogers" <irogers@google.com>
Cc: linux-perf-users@vger.kernel.org
Subject: Re: [PATCH 3/3] perf hist: Do not delete cumulative caller entries before stat_acc decays
Date: Mon, 26 Oct 2026 09:41:35 +0000	[thread overview]
Message-ID: <sashiko-outbox-184826@kernel.org> (raw)
In-Reply-To: <efe1d231090ef4dc43fe1f002a12c7c65c8ceda2.1792995775.git.irogers@google.com>

> When symbol_conf.cumulate_callchain is enabled (the default in
> 'perf top -g'), callchain parent/caller entries have he->stat.period == 0
> and accumulate their period in he->stat_acc->period.
> 
> hists__decay_entry() decays both he->stat.period and he->stat_acc->period,
> but only checks if he->stat.period == 0 as the return condition for
> deleting the entry in hists__decay_entries(). As a result, every callchain
> caller entry with 0 self-period is unconditionally deleted from the
> histogram on the first decay pass, destroying its callchain tree while it
> still has non-zero cumulative period.
> 
> Only mark an entry for deletion in hists__decay_entry() when both
> he->stat.period == 0 and (when cumulate_callchain is active)
> he->stat_acc->period == 0.
> 
> Signed-off-by: Ian Rogers <irogers@google.com>

Sashiko has reviewed this patch and found no issues.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1792995775.git.irogers@google.com?part=3


  reply	other threads:[~2026-10-26  9:41 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-26  6:50 [PATCH 0/3] perf: Fix libdw addr2line fallback, pr_debugN overhead, and cumulative hist decay Ian Rogers
2026-10-26  6:50 ` [PATCH 1/3] perf libdw: Optimize fallback logic for missing DWARF Ian Rogers
2026-10-26  9:31   ` sashiko-bot
2026-10-26  6:50 ` [PATCH 2/3] perf debug: Avoid calling eprintf() in pr_debugN() when verbose < n Ian Rogers
2026-10-26  9:35   ` sashiko-bot
2026-10-26  6:50 ` [PATCH 3/3] perf hist: Do not delete cumulative caller entries before stat_acc decays Ian Rogers
2026-10-26  9:41   ` sashiko-bot [this message]
2026-10-27 20:42 ` [PATCH 0/3] perf: Fix libdw addr2line fallback, pr_debugN overhead, and cumulative hist decay Arnaldo Carvalho de Melo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=sashiko-outbox-184826@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=irogers@google.com \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.