xemu/target
Peter Maydell c806bbe8c1 target/arm: arm_reset_sve_state() should set FPSR, not FPCR
The pseudocode ResetSVEState() does:
    FPSR = ZeroExtend(0x0800009f<31:0>, 64);
but QEMU's arm_reset_sve_state() called vfp_set_fpcr() by accident.

Before the advent of FEAT_AFP, this was only setting a collection of
RES0 bits, which vfp_set_fpsr() would then ignore, so the only effect
was that we didn't actually set the FPSR the way we are supposed to
do.  Once FEAT_AFP is implemented, setting the bottom bits of FPSR
will change the floating point behaviour.

Call vfp_set_fpsr(), as we ought to.

(Note for stable backports: commit 7f2a01e736 moved this function
from sme_helper.c to helper.c, but it had the same bug before the
move too.)

Cc: qemu-stable@nongnu.org
Fixes: f84734b874 ("target/arm: Implement SMSTART, SMSTOP")
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20250124162836.2332150-4-peter.maydell@linaro.org
(cherry picked from commit 1edc3d43f20df0d04f8d00b906ba19fed37512a5)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
2025-01-29 22:25:22 +03:00
..
alpha target/alpha: Explicitly set 2-NaN propagation rule 2024-11-05 10:09:56 +00:00
arm target/arm: arm_reset_sve_state() should set FPSR, not FPCR 2025-01-29 22:25:22 +03:00
avr target/avr: Use explicit little-endian LD/ST API 2024-10-15 12:13:59 -03:00
hexagon target/hexagon: Use explicit little-endian LD/ST API 2024-10-15 11:55:09 -03:00
hppa target/hppa: Explicitly set 2-NaN propagation rule 2024-11-05 10:09:54 +00:00
i386 i386/cpu: Mark avx10_version filtered when prefix is NULL 2025-01-17 21:54:51 +03:00
loongarch target/loongarch: Use actual operand size with vbsrl check 2024-12-29 01:50:54 +03:00
m68k target/m68k: Initialize float_status fields in gdb set/get functions 2024-11-05 10:09:54 +00:00
microblaze Misc HW patch queue 2024-11-06 17:28:45 +00:00
mips target-arm queue: 2024-11-05 21:27:18 +00:00
openrisc target/openrisc: Explicitly set 2-NaN propagation rule 2024-11-05 10:09:57 +00:00
ppc target/ppc: Fix THREAD_SIBLING_FOREACH for multi-socket 2024-11-27 02:49:31 +10:00
riscv target/riscv: Avoid bad shift in riscv_cpu_do_interrupt() 2024-12-03 12:26:24 +01:00
rx target/rx: Explicitly set 2-NaN propagation rule 2024-11-05 10:09:57 +00:00
s390x target/s390x: Fix the floating-point multiply-and-add NaN rules 2024-11-18 10:54:42 +01:00
sh4 license: Update deprecated SPDX tag LGPL-2.0+ to LGPL-2.0-or-later 2024-09-20 10:11:59 +03:00
sparc target/sparc: Explicitly set 2-NaN propagation rule 2024-11-05 10:09:55 +00:00
tricore target/tricore: Use tcg_constant_tl() instead of tcg_gen_movi_tl() 2024-10-15 12:13:59 -03:00
xtensa target/xtensa: Explicitly set 2-NaN propagation rule 2024-11-05 10:09:55 +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