]> git.proxmox.com Git - mirror_qemu.git/commitdiff
target/arm: Handle FPROUNDING_ODD in arm_rmode_to_sf
authorRichard Henderson <richard.henderson@linaro.org>
Sat, 25 Feb 2023 20:28:05 +0000 (10:28 -1000)
committerRichard Henderson <richard.henderson@linaro.org>
Mon, 13 Mar 2023 13:44:38 +0000 (06:44 -0700)
While this enumerator has been present since the first commit,
it isn't ever used.  The first actual use of round-to-odd came
with SVE, which currently uses float_round_to_odd instead of
the arm-specific enumerator.

Amusingly, the comment about unhandled TIEAWAY has been
out of date since the initial commit of translate-a64.c.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
target/arm/vfp_helper.c

index 24e3d820a5b9d415ba547357fdcf84319ff5ac3d..90cc324f712eed7a6875175c106c53877198186f 100644 (file)
@@ -1111,10 +1111,8 @@ int arm_rmode_to_sf(int rmode)
         rmode = float_round_ties_away;
         break;
     case FPROUNDING_ODD:
-        /* FIXME: add support for TIEAWAY and ODD */
-        qemu_log_mask(LOG_UNIMP, "arm: unimplemented rounding mode: %d\n",
-                      rmode);
-        /* fall through for now */
+        rmode = float_round_to_odd;
+        break;
     case FPROUNDING_TIEEVEN:
     default:
         rmode = float_round_nearest_even;