diff mbox series

[COMMITTED] math: Fix log10f on some ABIs

Message ID 20241107112205.503624-1-adhemerval.zanella@linaro.org
State New
Headers show
Series [COMMITTED] math: Fix log10f on some ABIs | expand

Commit Message

Adhemerval Zanella Nov. 7, 2024, 11:22 a.m. UTC
The commit 9247f53219 triggered some regressions on loongarch and
riscv:

math/test-float-log10
math/test-float32-log10

And it is due a wrong sync with CORE-MATH for special 0.0/-0.0
inputs.

Checked on aarch64-linux-gnu and loongarch64-linux-gnu-lp64d.
---
 sysdeps/ieee754/flt-32/e_log10f.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
index 058ce31f09..03d9e281f3 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
@@ -37,9 +37,8 @@  as_special (float x)
     return x; /* +inf */
   uint32_t ax = ux << 1;
   if (ax == 0u)
-    { /* -0.0 */
-      __math_divzerof (1);
-    }
+    /* -0.0 */
+    return  __math_divzerof (1);
   if (ax > 0xff000000u)
     return x + x; /* nan */
   return __math_invalidf (x);