[PATCH 5/8] math: Remove erfcf fma usage
Adhemerval Zanella
adhemerval.zanella@linaro.org
Fri Oct 10 17:49:23 GMT 2025
The fma is not required to provide correctly rounded and it helps
on !__FP_FAST_FMA ISAs.
---
sysdeps/ieee754/flt-32/s_erfcf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sysdeps/ieee754/flt-32/s_erfcf.c b/sysdeps/ieee754/flt-32/s_erfcf.c
index 955f129148d..7d77eceb9cb 100644
--- a/sysdeps/ieee754/flt-32/s_erfcf.c
+++ b/sysdeps/ieee754/flt-32/s_erfcf.c
@@ -140,7 +140,7 @@ __erfcf (float xf)
const double iln2 = 0x1.71547652b82fep+0;
const double ln2h = 0x1.62e42fefap-8;
const double ln2l = 0x1.cf79abd6f5dc8p-47;
- uint64_t jt = asuint64 (fma (x2, iln2, -(1024 + 0x1p-8)));
+ uint64_t jt = asuint64 (x2 * iln2 + -(1024 + 0x1p-8));
int64_t j = (int64_t) (jt << 12) >> 48;
double S = asdouble ((uint64_t)((j >> 7) + (0x3ff | sgn << 11)) << 52);
static const double ch[] =
--
2.43.0
More information about the Libc-alpha
mailing list