target/arm: Define CNTPCTSS_EL0 and CNTVCTSS_EL0
commit485eb324e352a53bdf99f90511bd546eebab68f5
authorPeter Maydell <peter.maydell@linaro.org>
Thu, 7 Mar 2024 12:19:03 +0000 (7 12:19 +0000)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 7 Mar 2024 12:19:03 +0000 (7 12:19 +0000)
tree0a7c85f7edacb820deb3040e733c99bf2a254ed3
parentdcdad2624b445f9ce1a3fdca6a0831d7a7abddd8
target/arm: Define CNTPCTSS_EL0 and CNTVCTSS_EL0

For FEAT_ECV, new registers CNTPCTSS_EL0 and CNTVCTSS_EL0 are
defined, which are "self-synchronized" views of the physical and
virtual counts as seen in the CNTPCT_EL0 and CNTVCT_EL0 registers
(meaning that no barriers are needed around accesses to them to
ensure that reads of them do not occur speculatively and out-of-order
with other instructions).

For QEMU, all our system registers are self-synchronized, so we can
simply copy the existing implementation of CNTPCT_EL0 and CNTVCT_EL0
to the new register encodings.

This means we now implement all the functionality required for
ID_AA64MMFR0_EL1.ECV == 0b0001.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20240301183219.2424889-7-peter.maydell@linaro.org
target/arm/helper.c