From: Leo Yan <leo.yan@arm.com>
To: Yicong Yang <yangyicong@huawei.com>
Cc: acme@kernel.org, namhyung@kernel.org, catalin.marinas@arm.com,
will@kernel.org, peterz@infradead.org, mingo@redhat.com,
mark.rutland@arm.com, jolsa@kernel.org, john.g.garry@oracle.com,
james.clark@linaro.org, leo.yan@linux.dev, irogers@google.com,
linux-arm-kernel@lists.infradead.org,
linux-perf-users@vger.kernel.org, jonathan.cameron@huawei.com,
hejunhao3@huawei.com, linuxarm@huawei.com,
wangyushan12@huawei.com, caijingtao@huawei.com,
xueshan2@huawei.com, prime.zeng@hisilicon.com,
yangyicong@hisilicon.com
Subject: Re: [PATCH v2 3/3] perf mem: Count L2 HITM for c2c statistic
Date: Wed, 21 May 2025 11:37:42 +0100 [thread overview]
Message-ID: <20250521103742.GB2565659@e132581.arm.com> (raw)
In-Reply-To: <20250425033845.57671-4-yangyicong@huawei.com>
On Fri, Apr 25, 2025 at 11:38:45AM +0800, Yicong Yang wrote:
> From: Yicong Yang <yangyicong@hisilicon.com>
>
> L2 HITM is not counted in c2c statistic decoding. Count it for lcl_hitm
> like how we handle L2 Peer snoop.
>
> Signed-off-by: Yicong Yang <yangyicong@hisilicon.com>
Reviewed-by: Leo Yan <leo.yan@arm.com>
> ---
> tools/perf/util/mem-events.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/tools/perf/util/mem-events.c b/tools/perf/util/mem-events.c
> index 884d9aebce91..a384a866a562 100644
> --- a/tools/perf/util/mem-events.c
> +++ b/tools/perf/util/mem-events.c
> @@ -680,7 +680,10 @@ do { \
> if (lvl & P(LVL, LFB)) stats->ld_fbhit++;
> if (lvl & P(LVL, L1 )) stats->ld_l1hit++;
> if (lvl & P(LVL, L2)) {
> - stats->ld_l2hit++;
> + if (snoop & P(SNOOP, HITM))
> + HITM_INC(lcl_hitm);
> + else
> + stats->ld_l2hit++;
>
> if (snoopx & P(SNOOPX, PEER))
> PEER_INC(lcl_peer);
>
> --
> 2.24.0
>
next prev parent reply other threads:[~2025-05-21 10:37 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-25 3:38 [PATCH v2 0/3] Add support for SPE Data Source packet on HiSilicon HIP12 Yicong Yang
2025-04-25 3:38 ` [PATCH v2 1/3] arm64: cputype: Add cputype definition for HIP12 Yicong Yang
2025-05-22 9:13 ` Yicong Yang
2025-05-22 10:25 ` Will Deacon
2025-04-25 3:38 ` [PATCH v2 2/3] perf arm-spe: Add support for SPE Data Source packet on HiSilicon HIP12 Yicong Yang
2025-05-21 10:35 ` Leo Yan
2025-04-25 3:38 ` [PATCH v2 3/3] perf mem: Count L2 HITM for c2c statistic Yicong Yang
2025-05-21 10:37 ` Leo Yan [this message]
2025-05-14 3:38 ` [PATCH v2 0/3] Add support for SPE Data Source packet on HiSilicon HIP12 Yicong Yang
2025-05-21 14:49 ` Arnaldo Carvalho de Melo
2025-05-22 9:07 ` Yicong Yang
2025-05-26 11:06 ` Yicong Yang
2025-05-27 20:54 ` Arnaldo Carvalho de Melo
2025-05-22 10:50 ` Will Deacon
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=20250521103742.GB2565659@e132581.arm.com \
--to=leo.yan@arm.com \
--cc=acme@kernel.org \
--cc=caijingtao@huawei.com \
--cc=catalin.marinas@arm.com \
--cc=hejunhao3@huawei.com \
--cc=irogers@google.com \
--cc=james.clark@linaro.org \
--cc=john.g.garry@oracle.com \
--cc=jolsa@kernel.org \
--cc=jonathan.cameron@huawei.com \
--cc=leo.yan@linux.dev \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=linuxarm@huawei.com \
--cc=mark.rutland@arm.com \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
--cc=prime.zeng@hisilicon.com \
--cc=wangyushan12@huawei.com \
--cc=will@kernel.org \
--cc=xueshan2@huawei.com \
--cc=yangyicong@hisilicon.com \
--cc=yangyicong@huawei.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).