target/sparc: Merge check_ieee_exceptions with FPop helpers
commitdb71391123dccccc2c8632a6f5ad451369a35391
authorRichard Henderson <richard.henderson@linaro.org>
Fri, 3 Nov 2023 17:38:37 +0000 (3 10:38 -0700)
committerRichard Henderson <richard.henderson@linaro.org>
Sat, 3 Feb 2024 06:46:10 +0000 (3 16:46 +1000)
treebfdadec8e2c752f17b6727959a37602722b5c472
parentefeb8b07502570aa133a87f7430dd919a9f5c37a
target/sparc: Merge check_ieee_exceptions with FPop helpers

If an exception is to be raised, the destination fp register
should be unmodified.  The current implementation is incorrect,
in that double results will be written back before calling
gen_helper_check_ieee_exceptions, despite the placement of
gen_store_fpr_D, since gen_dest_fpr_D returns cpu_fpr[].

We can simplify the entire implementation by having each
FPOp helper call check_ieee_exceptions.  For the moment this
requires that all FPop helpers write to the TCG global cpu_fsr,
so remove TCG_CALL_NO_WG from the DEF_HELPER_FLAGS_*.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Tested-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Acked-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Message-Id: <20231103173841.33651-19-richard.henderson@linaro.org>
target/sparc/fop_helper.c
target/sparc/helper.h
target/sparc/translate.c