qemu/target
Peter Maydell 243705aa6e target/arm: Fix return value from LDSMIN/LDSMAX 8/16 bit atomics
The atomic memory operations are supposed to return the old memory
data value in the destination register.  This value is not
sign-extended, even if the operation is the signed minimum or
maximum.  (In the pseudocode for the instructions the returned data
value is passed to ZeroExtend() to create the value in the register.)

We got this wrong because we were doing a 32-to-64 zero extend on the
result for 8 and 16 bit data values, rather than the correct amount
of zero extension.

Fix the bug by using ext8u and ext16u for the MO_8 and MO_16 data
sizes rather than ext32u.

Cc: qemu-stable@nongnu.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20230602155223.2040685-2-peter.maydell@linaro.org
2023-06-19 11:20:18 +01:00
..
alpha accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
arm target/arm: Fix return value from LDSMIN/LDSMAX 8/16 bit atomics 2023-06-19 11:20:18 +01:00
avr accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
cris accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
hexagon target/*: Add missing includes of exec/translation-block.h 2023-06-05 12:04:29 -07:00
hppa target/hppa/meson: Only build int_helper.o with system emulation 2023-06-13 11:28:58 +02:00
i386 target/i386: Rename helper template headers as '.h.inc' 2023-06-13 11:28:58 +02:00
loongarch target/loongarch: Fix CSR.DMW0-3.VSEG check 2023-06-16 17:58:46 +08:00
m68k target/m68k/fpu_helper: Use FloatRelation enum to hold comparison result 2023-06-09 23:38:16 +03:00
microblaze accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
mips target/*: Add missing includes of exec/translation-block.h 2023-06-05 12:04:29 -07:00
nios2 accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
openrisc accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
ppc target/ppc: Implement gathering irq statistics 2023-06-10 10:19:24 -03:00
riscv target/riscv: Smepmp: Return error when access permission not allowed in PMP 2023-06-13 17:45:30 +10:00
rx accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
s390x * Fix emulated LCCB, LOCFHR, MXDB and MXDBR s390x instructions 2023-06-06 07:07:37 -07:00
sh4 accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
sparc accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
tricore target/tricore: Fix wrong PSW for call insns 2023-06-07 18:20:48 +02:00
xtensa accel/tcg: Introduce translator_io_start 2023-06-05 12:04:29 -07:00
Kconfig hw/loongarch: Add support loongson3 virt machine type. 2022-06-06 18:09:03 +00:00
meson.build target/loongarch: Add target build suport 2022-06-06 18:09:03 +00:00