diff options
author | Vineet Gupta <vgupta@synopsys.com> | 2020-05-29 15:58:33 -0700 |
---|---|---|
committer | Vineet Gupta <vgupta@synopsys.com> | 2020-06-03 10:23:28 -0700 |
commit | 628d90c5f97b6f0f8b79a079b682febb1f486a38 (patch) | |
tree | b62fc668b7ba6f44cfdd8e74617f563929c80506 /sysdeps/ieee754/ldbl-128/s_fmal.c | |
parent | 3374868668e708581ca06e256f6122518c89a8ad (diff) | |
download | glibc-628d90c5f97b6f0f8b79a079b682febb1f486a38.tar.gz glibc-628d90c5f97b6f0f8b79a079b682febb1f486a38.tar.xz glibc-628d90c5f97b6f0f8b79a079b682febb1f486a38.zip |
ieee754: provide gcc builtins based generic fma functions
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Diffstat (limited to 'sysdeps/ieee754/ldbl-128/s_fmal.c')
-rw-r--r-- | sysdeps/ieee754/ldbl-128/s_fmal.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sysdeps/ieee754/ldbl-128/s_fmal.c b/sysdeps/ieee754/ldbl-128/s_fmal.c index 7475015bce..a610499e47 100644 --- a/sysdeps/ieee754/ldbl-128/s_fmal.c +++ b/sysdeps/ieee754/ldbl-128/s_fmal.c @@ -25,6 +25,7 @@ #include <math_private.h> #include <libm-alias-ldouble.h> #include <tininess.h> +#include <math-use-builtins.h> /* This implementation uses rounding to odd to avoid problems with double rounding. See a paper by Boldo and Melquiond: @@ -33,6 +34,9 @@ _Float128 __fmal (_Float128 x, _Float128 y, _Float128 z) { +#if USE_FMAL_BUILTIN + return __builtin_fmal (x, y, z); +#else union ieee854_long_double u, v, w; int adjust = 0; u.d = x; @@ -296,5 +300,6 @@ __fmal (_Float128 x, _Float128 y, _Float128 z) v.ieee.mantissa3 |= j; return v.d * L(0x1p-228); } +#endif /* ! USE_FMAL_BUILTIN */ } libm_alias_ldouble (__fma, fma) |