]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
perf arm-spe: Fix load-store operation checking
authorLeo Yan <leo.yan@arm.com>
Tue, 4 Mar 2025 11:12:34 +0000 (11:12 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 10 Apr 2025 12:37:33 +0000 (14:37 +0200)
commit31ebc5701a829560ca3a156ad9342ef4abdbc4e9
treeb5be385dadd08a62a467b7dd6f843160cd290c9d
parentd3f0bad2c43e7a145033680e47b393f0cbc0fa01
perf arm-spe: Fix load-store operation checking

[ Upstream commit e1d47850bbf79a541c9b3bacdd562f5e0112274d ]

The ARM_SPE_OP_LD and ARM_SPE_OP_ST operations are secondary operation
type, they are overlapping with other second level's operation types
belonging to SVE and branch operations.  As a result, a non load-store
operation can be parsed for data source and memory sample.

To fix the issue, this commit introduces a is_ldst_op() macro for
checking LDST operation, and apply the checking when synthesize data
source and memory samples.

Fixes: a89dbc9b988f ("perf arm-spe: Set sample's data source field")
Signed-off-by: Leo Yan <leo.yan@arm.com>
Reviewed-by: James Clark <james.clark@linaro.org>
Link: https://lore.kernel.org/r/20250304111240.3378214-7-leo.yan@arm.com
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
tools/perf/util/arm-spe.c