]> www.infradead.org Git - users/dwmw2/qemu.git/commit
target/arm: Correct names of VFP VFNMA and VFNMS insns
authorPeter Maydell <peter.maydell@linaro.org>
Fri, 30 Aug 2024 15:21:56 +0000 (16:21 +0100)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 5 Sep 2024 12:12:37 +0000 (13:12 +0100)
commit76dd36660b2553616b099ca6cd914f01a7997b2c
tree6780f8adce295f8ab7b138b2995a59f20cf5e1c3
parentc2a33809e5c119f849625132544c19a180115549
target/arm: Correct names of VFP VFNMA and VFNMS insns

In vfp.decode we have the names of the VFNMA and VFNMS instructions
the wrong way around.  The architecture says that bit 6 is the 'op'
bit, which is 1 for VFNMA and 0 for VFNMS, but we label these two
lines of decode the other way around.  This doesn't cause any
user-visible problem because in the handling of these functions in
translate-vfp.c we give VFNMA the behaviour specified for VFNMS and
vice-versa, but it's confusing when reading the code.

Switch the names of the VFP VFNMA and VFNMS instructions in
the decode file and flip the behaviour also.

NB: the instructions VFMA and VFMS *are* decoded with op=0 for
VFMA and op=1 for VFMS; the confusion probably arose because
we assumed VFNMA and VFNMS to be the same way around.

Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2536
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Message-id: 20240830152156.2046590-1-peter.maydell@linaro.org
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
target/arm/tcg/translate-vfp.c
target/arm/tcg/vfp.decode