diff options
Diffstat (limited to 'sysdeps/ieee754/ldbl-128/k_sincosl.c')
-rw-r--r-- | sysdeps/ieee754/ldbl-128/k_sincosl.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sysdeps/ieee754/ldbl-128/k_sincosl.c b/sysdeps/ieee754/ldbl-128/k_sincosl.c index 98c5d62780..00a21c45d1 100644 --- a/sysdeps/ieee754/ldbl-128/k_sincosl.c +++ b/sysdeps/ieee754/ldbl-128/k_sincosl.c @@ -132,7 +132,11 @@ __kernel_sincosl(long double x, long double y, long double *sinx, long double *c cosl(h+l) = cosl(h)cosl(l) - sinl(h)sinl(l). */ index = 0x3ffe - (tix >> 16); hix = (tix + (0x200 << index)) & (0xfffffc00 << index); - x = fabsl (x); + if (signbit (x)) + { + x = -x; + y = -y; + } switch (index) { case 0: index = ((45 << 10) + hix - 0x3ffe0000) >> 8; break; |