qemu-cr16/target
Richard Henderson 4dea00368d accel/tcg: Introduce and use MO_ALIGN_TLB_ONLY
For Arm, we need 3 cases: (1) the alignment required when accessing
Normal memory, (2) the alignment required when accessing Device memory,
and (3) the atomicity of the access.

When we added TLB_CHECK_ALIGNED, we assumed that cases 2 and 3 were
identical, and thus used memop_atomicity_bits for TLB_CHECK_ALIGNED.

This is incorrect for multiple reasons, including that the atomicity
of the access is adjusted depending on whether or not we are executing
within a serial context.

For Arm, what is true is that there is an underlying alignment
requirement of the access, and for that access Normal memory
will support unalignement.

Introduce MO_ALIGN_TLB_ONLY to indicate that the alignment
specified in MO_AMASK only applies when the TLB entry has
TLB_CHECK_ALIGNED set; otherwise no alignment required.

Introduce memop_tlb_alignment_bits with an additional bool
argument that specifies whether TLB_CHECK_ALIGNED is set.
All other usage of memop_alignment_bits assumes it is not.

Remove memop_atomicity_bits as unused; it didn't properly
support MO_ATOM_SUBWORD anyway.

Update target/arm finalize_memop_atom to set MO_ALIGN_TLB_ONLY
when strict alignment isn't otherwise required.

Suggested-by: Peter Maydell <peter.maydell@linaro.org>
Resolves: https://gitlab.com/qemu-project/qemu/-/issues/3171
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
2025-10-31 12:49:46 +01:00
..
alpha target/alpha: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
arm accel/tcg: Introduce and use MO_ALIGN_TLB_ONLY 2025-10-31 12:49:46 +01:00
avr target/avr: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
hexagon target/hexagon: Only indent on linux 2025-10-17 13:45:46 -07:00
hppa target/hppa: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
i386 target/i386: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
loongarch target/loongarch: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
m68k target/m68k: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
microblaze maintainer updates for 10.2 2025-10-30 09:25:15 +01:00
mips target/mips: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
openrisc target/openrisc: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
ppc target/ppc: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
riscv target/riscv: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
rx target/rx: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
s390x target/s390x: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
sh4 target/sh4: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
sparc target/sparc: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
tricore target/tricore: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
xtensa target/xtensa: call plugin trap callbacks 2025-10-29 14:12:43 +00:00
Kconfig target/cris: Remove the deprecated CRIS target 2024-09-13 20:11:13 +02:00
meson.build target/cris: Remove the deprecated CRIS target 2024-09-13 20:11:13 +02:00