aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog30
-rw-r--r--NEWS8
-rw-r--r--math/auto-libm-test-in9
-rw-r--r--math/auto-libm-test-out200
-rw-r--r--sysdeps/i386/fpu/e_asin.S34
-rw-r--r--sysdeps/i386/fpu/e_asinf.S34
-rw-r--r--sysdeps/ieee754/dbl-64/e_asin.c12
-rw-r--r--sysdeps/ieee754/flt-32/e_asinf.c6
-rw-r--r--sysdeps/ieee754/ldbl-128/e_asinl.c6
-rw-r--r--sysdeps/ieee754/ldbl-128ibm/e_asinl.c6
-rw-r--r--sysdeps/ieee754/ldbl-96/e_asinl.c6
-rw-r--r--sysdeps/x86_64/fpu/multiarch/e_asin.c1
12 files changed, 240 insertions, 112 deletions
diff --git a/ChangeLog b/ChangeLog
index ac6110b..1cc3de6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,35 @@
2015-02-26 Joseph Myers <joseph@codesourcery.com>
+ [BZ #16351]
+ * sysdeps/i386/fpu/e_asin.S (dbl_min): New object.
+ (MO): New macro.
+ (__ieee754_asin): Force underflow exception for results with small
+ absolute value.
+ * sysdeps/i386/fpu/e_asinf.S (flt_min): New object.
+ (MO): New macro.
+ (__ieee754_asinf): Force underflow exception for results with
+ small absolute value.
+ * sysdeps/ieee754/dbl-64/e_asin.c: Include <float.h> and <math.h>.
+ (__ieee754_asin): Force underflow exception for results with small
+ absolute value.
+ * sysdeps/ieee754/flt-32/e_asinf.c: Include <float.h>.
+ (__ieee754_asinf): Force underflow exception for results with
+ small absolute value.
+ * sysdeps/ieee754/ldbl-128/e_asinl.c: Include <float.h>.
+ (__ieee754_asinl): Force underflow exception for results with
+ small absolute value.
+ * sysdeps/ieee754/ldbl-128ibm/e_asinl.c: Include <float.h>.
+ (__ieee754_asinl): Force underflow exception for results with
+ small absolute value.
+ * sysdeps/ieee754/ldbl-96/e_asinl.c: Include <float.h>.
+ (__ieee754_asinl): Force underflow exception for results with
+ small absolute value.
+ * sysdeps/x86_64/fpu/multiarch/e_asin.c [HAVE_FMA4_SUPPORT]:
+ Include <math.h>.
+ * math/auto-libm-test-in: Do not mark underflow exceptions as
+ possibly missing for bug 16351.
+ * math/auto-libm-test-out: Regenerated.
+
[BZ #18030]
* sysdeps/ieee754/ldbl-128ibm/s_logbl.c (__logbl): Adjust exponent
of power of 2 down when low part has opposite sign.
diff --git a/NEWS b/NEWS
index f09ffb1..40959d3 100644
--- a/NEWS
+++ b/NEWS
@@ -9,10 +9,10 @@ Version 2.22
* The following bugs are resolved with this release:
- 4719, 14841, 13064, 14094, 15319, 15467, 15790, 15969, 16560, 16783,
- 17269, 17523, 17569, 17588, 17792, 17836, 17912, 17916, 17932, 17944,
- 17949, 17964, 17965, 17967, 17969, 17978, 17987, 17991, 17996, 17998,
- 17999, 18019, 18020, 18029, 18030, 18032.
+ 4719, 14841, 13064, 14094, 15319, 15467, 15790, 15969, 16351, 16560,
+ 16783, 17269, 17523, 17569, 17588, 17792, 17836, 17912, 17916, 17932,
+ 17944, 17949, 17964, 17965, 17967, 17969, 17978, 17987, 17991, 17996,
+ 17998, 17999, 18019, 18020, 18029, 18030, 18032.
* Character encoding and ctype tables were updated to Unicode 7.0.0, using
new generator scripts contributed by Pravin Satpute and Mike FABIAN (Red
diff --git a/math/auto-libm-test-in b/math/auto-libm-test-in
index df51c26..bd85805 100644
--- a/math/auto-libm-test-in
+++ b/math/auto-libm-test-in
@@ -91,11 +91,10 @@ asin 0x0.ffffffffffffp0
asin -0x0.ffffffffffffp0
asin 0x0.ffffffffffffffffp0
asin -0x0.ffffffffffffffffp0
-# Bug 16351: underflow exception may be missing.
-asin min missing-underflow
-asin -min missing-underflow
-asin min_subnorm missing-underflow
-asin -min_subnorm missing-underflow
+asin min
+asin -min
+asin min_subnorm
+asin -min_subnorm
asinh 0
asinh -0
diff --git a/math/auto-libm-test-out b/math/auto-libm-test-out
index 83170d9..67804a5 100644
--- a/math/auto-libm-test-out
+++ b/math/auto-libm-test-out
@@ -2855,7 +2855,7 @@ asin -0x0.ffffffffffffffffp0
= asin tonearest ldbl-128ibm -0xf.fffffffffffffffp-4L : -0x1.921fb542d8c79e0195cffc0e308p+0L : inexact-ok
= asin towardzero ldbl-128ibm -0xf.fffffffffffffffp-4L : -0x1.921fb542d8c79e0195cffc0e308p+0L : inexact-ok
= asin upward ldbl-128ibm -0xf.fffffffffffffffp-4L : -0x1.921fb542d8c79e0195cffc0e308p+0L : inexact-ok
-asin min missing-underflow
+asin min
= asin downward flt-32 0x4p-128f : 0x4p-128f : inexact-ok underflow-ok errno-erange-ok
= asin tonearest flt-32 0x4p-128f : 0x4p-128f : inexact-ok underflow-ok errno-erange-ok
= asin towardzero flt-32 0x4p-128f : 0x4p-128f : inexact-ok underflow-ok errno-erange-ok
@@ -2896,10 +2896,10 @@ asin min missing-underflow
= asin tonearest ldbl-128 0x4p-1024L : 0x4p-1024L : inexact-ok
= asin towardzero ldbl-128 0x4p-1024L : 0x4p-1024L : inexact-ok
= asin upward ldbl-128 0x4p-1024L : 0x4.0000000000000000000000000004p-1024L : inexact-ok
-= asin downward ldbl-128ibm 0x4p-1024L : 0x4p-1024L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128ibm 0x4p-1024L : 0x4p-1024L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128ibm 0x4p-1024L : 0x4p-1024L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128ibm 0x4p-1024L : 0x4.0000000000004p-1024L : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward ldbl-128ibm 0x4p-1024L : 0x4p-1024L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128ibm 0x4p-1024L : 0x4p-1024L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128ibm 0x4p-1024L : 0x4p-1024L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128ibm 0x4p-1024L : 0x4.0000000000004p-1024L : inexact-ok underflow errno-erange-ok
= asin downward ldbl-96-intel 0x4p-16384L : 0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin tonearest ldbl-96-intel 0x4p-16384L : 0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin towardzero ldbl-96-intel 0x4p-16384L : 0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
@@ -2912,18 +2912,18 @@ asin min missing-underflow
= asin tonearest ldbl-128 0x4p-16384L : 0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin towardzero ldbl-128 0x4p-16384L : 0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin upward ldbl-128 0x4p-16384L : 0x4.0000000000000000000000000004p-16384L : inexact-ok underflow-ok errno-erange-ok
-= asin downward ldbl-96-intel 0x2p-16384L : 0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-96-intel 0x2p-16384L : 0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-96-intel 0x2p-16384L : 0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-96-intel 0x2p-16384L : 0x2.0000000000000008p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward ldbl-96-intel 0x2p-16384L : 0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-96-intel 0x2p-16384L : 0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-96-intel 0x2p-16384L : 0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-96-intel 0x2p-16384L : 0x2.0000000000000008p-16384L : inexact-ok underflow errno-erange-ok
= asin downward ldbl-96-m68k 0x2p-16384L : 0x2p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin tonearest ldbl-96-m68k 0x2p-16384L : 0x2p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin towardzero ldbl-96-m68k 0x2p-16384L : 0x2p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin upward ldbl-96-m68k 0x2p-16384L : 0x2.0000000000000004p-16384L : inexact-ok underflow-ok errno-erange-ok
-= asin downward ldbl-128 0x2p-16384L : 0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128 0x2p-16384L : 0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128 0x2p-16384L : 0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128 0x2p-16384L : 0x2.0000000000000000000000000004p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward ldbl-128 0x2p-16384L : 0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128 0x2p-16384L : 0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128 0x2p-16384L : 0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128 0x2p-16384L : 0x2.0000000000000000000000000004p-16384L : inexact-ok underflow errno-erange-ok
= asin downward dbl-64 0x8p-972 : 0x8p-972 : inexact-ok
= asin tonearest dbl-64 0x8p-972 : 0x8p-972 : inexact-ok
= asin towardzero dbl-64 0x8p-972 : 0x8p-972 : inexact-ok
@@ -2944,7 +2944,7 @@ asin min missing-underflow
= asin tonearest ldbl-128ibm 0x8p-972L : 0x8p-972L : inexact-ok underflow-ok errno-erange-ok
= asin towardzero ldbl-128ibm 0x8p-972L : 0x8p-972L : inexact-ok underflow-ok errno-erange-ok
= asin upward ldbl-128ibm 0x8p-972L : 0x8.00000000000000000000000004p-972L : inexact-ok underflow-ok errno-erange-ok
-asin -min missing-underflow
+asin -min
= asin downward flt-32 -0x4p-128f : -0x4.000008p-128f : inexact-ok underflow-ok errno-erange-ok
= asin tonearest flt-32 -0x4p-128f : -0x4p-128f : inexact-ok underflow-ok errno-erange-ok
= asin towardzero flt-32 -0x4p-128f : -0x4p-128f : inexact-ok underflow-ok errno-erange-ok
@@ -2985,10 +2985,10 @@ asin -min missing-underflow
= asin tonearest ldbl-128 -0x4p-1024L : -0x4p-1024L : inexact-ok
= asin towardzero ldbl-128 -0x4p-1024L : -0x4p-1024L : inexact-ok
= asin upward ldbl-128 -0x4p-1024L : -0x4p-1024L : inexact-ok
-= asin downward ldbl-128ibm -0x4p-1024L : -0x4.0000000000004p-1024L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128ibm -0x4p-1024L : -0x4p-1024L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128ibm -0x4p-1024L : -0x4p-1024L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128ibm -0x4p-1024L : -0x4p-1024L : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward ldbl-128ibm -0x4p-1024L : -0x4.0000000000004p-1024L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128ibm -0x4p-1024L : -0x4p-1024L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128ibm -0x4p-1024L : -0x4p-1024L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128ibm -0x4p-1024L : -0x4p-1024L : inexact-ok underflow errno-erange-ok
= asin downward ldbl-96-intel -0x4p-16384L : -0x4.0000000000000008p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin tonearest ldbl-96-intel -0x4p-16384L : -0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin towardzero ldbl-96-intel -0x4p-16384L : -0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
@@ -3001,18 +3001,18 @@ asin -min missing-underflow
= asin tonearest ldbl-128 -0x4p-16384L : -0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin towardzero ldbl-128 -0x4p-16384L : -0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin upward ldbl-128 -0x4p-16384L : -0x4p-16384L : inexact-ok underflow-ok errno-erange-ok
-= asin downward ldbl-96-intel -0x2p-16384L : -0x2.0000000000000008p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-96-intel -0x2p-16384L : -0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-96-intel -0x2p-16384L : -0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-96-intel -0x2p-16384L : -0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward ldbl-96-intel -0x2p-16384L : -0x2.0000000000000008p-16384L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-96-intel -0x2p-16384L : -0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-96-intel -0x2p-16384L : -0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-96-intel -0x2p-16384L : -0x2p-16384L : inexact-ok underflow errno-erange-ok
= asin downward ldbl-96-m68k -0x2p-16384L : -0x2.0000000000000004p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin tonearest ldbl-96-m68k -0x2p-16384L : -0x2p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin towardzero ldbl-96-m68k -0x2p-16384L : -0x2p-16384L : inexact-ok underflow-ok errno-erange-ok
= asin upward ldbl-96-m68k -0x2p-16384L : -0x2p-16384L : inexact-ok underflow-ok errno-erange-ok
-= asin downward ldbl-128 -0x2p-16384L : -0x2.0000000000000000000000000004p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128 -0x2p-16384L : -0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128 -0x2p-16384L : -0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128 -0x2p-16384L : -0x2p-16384L : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward ldbl-128 -0x2p-16384L : -0x2.0000000000000000000000000004p-16384L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128 -0x2p-16384L : -0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128 -0x2p-16384L : -0x2p-16384L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128 -0x2p-16384L : -0x2p-16384L : inexact-ok underflow errno-erange-ok
= asin downward dbl-64 -0x8p-972 : -0x8.0000000000008p-972 : inexact-ok
= asin tonearest dbl-64 -0x8p-972 : -0x8p-972 : inexact-ok
= asin towardzero dbl-64 -0x8p-972 : -0x8p-972 : inexact-ok
@@ -3033,11 +3033,11 @@ asin -min missing-underflow
= asin tonearest ldbl-128ibm -0x8p-972L : -0x8p-972L : inexact-ok underflow-ok errno-erange-ok
= asin towardzero ldbl-128ibm -0x8p-972L : -0x8p-972L : inexact-ok underflow-ok errno-erange-ok
= asin upward ldbl-128ibm -0x8p-972L : -0x8p-972L : inexact-ok underflow-ok errno-erange-ok
-asin min_subnorm missing-underflow
-= asin downward flt-32 0x8p-152f : 0x8p-152f : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest flt-32 0x8p-152f : 0x8p-152f : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero flt-32 0x8p-152f : 0x8p-152f : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward flt-32 0x8p-152f : 0x1p-148f : inexact-ok underflow underflow-ok errno-erange-ok
+asin min_subnorm
+= asin downward flt-32 0x8p-152f : 0x8p-152f : inexact-ok underflow errno-erange-ok
+= asin tonearest flt-32 0x8p-152f : 0x8p-152f : inexact-ok underflow errno-erange-ok
+= asin towardzero flt-32 0x8p-152f : 0x8p-152f : inexact-ok underflow errno-erange-ok
+= asin upward flt-32 0x8p-152f : 0x1p-148f : inexact-ok underflow errno-erange-ok
= asin downward dbl-64 0x8p-152 : 0x8p-152 : inexact-ok
= asin tonearest dbl-64 0x8p-152 : 0x8p-152 : inexact-ok
= asin towardzero dbl-64 0x8p-152 : 0x8p-152 : inexact-ok
@@ -3058,10 +3058,10 @@ asin min_subnorm missing-underflow
= asin tonearest ldbl-128ibm 0x8p-152L : 0x8p-152L : inexact-ok
= asin towardzero ldbl-128ibm 0x8p-152L : 0x8p-152L : inexact-ok
= asin upward ldbl-128ibm 0x8p-152L : 0x8.00000000000000000000000004p-152L : inexact-ok
-= asin downward dbl-64 0x4p-1076 : 0x4p-1076 : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest dbl-64 0x4p-1076 : 0x4p-1076 : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero dbl-64 0x4p-1076 : 0x4p-1076 : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward dbl-64 0x4p-1076 : 0x8p-1076 : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward dbl-64 0x4p-1076 : 0x4p-1076 : inexact-ok underflow errno-erange-ok
+= asin tonearest dbl-64 0x4p-1076 : 0x4p-1076 : inexact-ok underflow errno-erange-ok
+= asin towardzero dbl-64 0x4p-1076 : 0x4p-1076 : inexact-ok underflow errno-erange-ok
+= asin upward dbl-64 0x4p-1076 : 0x8p-1076 : inexact-ok underflow errno-erange-ok
= asin downward ldbl-96-intel 0x4p-1076L : 0x4p-1076L : inexact-ok
= asin tonearest ldbl-96-intel 0x4p-1076L : 0x4p-1076L : inexact-ok
= asin towardzero ldbl-96-intel 0x4p-1076L : 0x4p-1076L : inexact-ok
@@ -3074,39 +3074,39 @@ asin min_subnorm missing-underflow
= asin tonearest ldbl-128 0x4p-1076L : 0x4p-1076L : inexact-ok
= asin towardzero ldbl-128 0x4p-1076L : 0x4p-1076L : inexact-ok
= asin upward ldbl-128 0x4p-1076L : 0x4.0000000000000000000000000004p-1076L : inexact-ok
-= asin downward ldbl-128ibm 0x4p-1076L : 0x4p-1076L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128ibm 0x4p-1076L : 0x4p-1076L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128ibm 0x4p-1076L : 0x4p-1076L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128ibm 0x4p-1076L : 0x8p-1076L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-96-intel 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-96-intel 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-96-intel 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-96-intel 0x8p-16448L : 0x1p-16444L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-96-m68k 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-96-m68k 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-96-m68k 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-96-m68k 0x8p-16448L : 0xcp-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-128 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128 0x8p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128 0x8p-16448L : 0x8.000000000004p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-96-m68k 0x4p-16448L : 0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-96-m68k 0x4p-16448L : 0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-96-m68k 0x4p-16448L : 0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-96-m68k 0x4p-16448L : 0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-128 0x4p-16448L : 0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128 0x4p-16448L : 0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128 0x4p-16448L : 0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128 0x4p-16448L : 0x4.000000000004p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-128 0x4p-16496L : 0x4p-16496L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128 0x4p-16496L : 0x4p-16496L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128 0x4p-16496L : 0x4p-16496L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128 0x4p-16496L : 0x8p-16496L : inexact-ok underflow underflow-ok errno-erange-ok
-asin -min_subnorm missing-underflow
-= asin downward flt-32 -0x8p-152f : -0x1p-148f : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest flt-32 -0x8p-152f : -0x8p-152f : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero flt-32 -0x8p-152f : -0x8p-152f : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward flt-32 -0x8p-152f : -0x8p-152f : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward ldbl-128ibm 0x4p-1076L : 0x4p-1076L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128ibm 0x4p-1076L : 0x4p-1076L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128ibm 0x4p-1076L : 0x4p-1076L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128ibm 0x4p-1076L : 0x8p-1076L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-96-intel 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-96-intel 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-96-intel 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-96-intel 0x8p-16448L : 0x1p-16444L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-96-m68k 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-96-m68k 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-96-m68k 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-96-m68k 0x8p-16448L : 0xcp-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-128 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128 0x8p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128 0x8p-16448L : 0x8.000000000004p-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-96-m68k 0x4p-16448L : 0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-96-m68k 0x4p-16448L : 0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-96-m68k 0x4p-16448L : 0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-96-m68k 0x4p-16448L : 0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-128 0x4p-16448L : 0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128 0x4p-16448L : 0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128 0x4p-16448L : 0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128 0x4p-16448L : 0x4.000000000004p-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-128 0x4p-16496L : 0x4p-16496L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128 0x4p-16496L : 0x4p-16496L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128 0x4p-16496L : 0x4p-16496L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128 0x4p-16496L : 0x8p-16496L : inexact-ok underflow errno-erange-ok
+asin -min_subnorm
+= asin downward flt-32 -0x8p-152f : -0x1p-148f : inexact-ok underflow errno-erange-ok
+= asin tonearest flt-32 -0x8p-152f : -0x8p-152f : inexact-ok underflow errno-erange-ok
+= asin towardzero flt-32 -0x8p-152f : -0x8p-152f : inexact-ok underflow errno-erange-ok
+= asin upward flt-32 -0x8p-152f : -0x8p-152f : inexact-ok underflow errno-erange-ok
= asin downward dbl-64 -0x8p-152 : -0x8.0000000000008p-152 : inexact-ok
= asin tonearest dbl-64 -0x8p-152 : -0x8p-152 : inexact-ok
= asin towardzero dbl-64 -0x8p-152 : -0x8p-152 : inexact-ok
@@ -3127,10 +3127,10 @@ asin -min_subnorm missing-underflow
= asin tonearest ldbl-128ibm -0x8p-152L : -0x8p-152L : inexact-ok
= asin towardzero ldbl-128ibm -0x8p-152L : -0x8p-152L : inexact-ok
= asin upward ldbl-128ibm -0x8p-152L : -0x8p-152L : inexact-ok
-= asin downward dbl-64 -0x4p-1076 : -0x8p-1076 : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest dbl-64 -0x4p-1076 : -0x4p-1076 : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero dbl-64 -0x4p-1076 : -0x4p-1076 : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward dbl-64 -0x4p-1076 : -0x4p-1076 : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward dbl-64 -0x4p-1076 : -0x8p-1076 : inexact-ok underflow errno-erange-ok
+= asin tonearest dbl-64 -0x4p-1076 : -0x4p-1076 : inexact-ok underflow errno-erange-ok
+= asin towardzero dbl-64 -0x4p-1076 : -0x4p-1076 : inexact-ok underflow errno-erange-ok
+= asin upward dbl-64 -0x4p-1076 : -0x4p-1076 : inexact-ok underflow errno-erange-ok
= asin downward ldbl-96-intel -0x4p-1076L : -0x4.0000000000000008p-1076L : inexact-ok
= asin tonearest ldbl-96-intel -0x4p-1076L : -0x4p-1076L : inexact-ok
= asin towardzero ldbl-96-intel -0x4p-1076L : -0x4p-1076L : inexact-ok
@@ -3143,34 +3143,34 @@ asin -min_subnorm missing-underflow
= asin tonearest ldbl-128 -0x4p-1076L : -0x4p-1076L : inexact-ok
= asin towardzero ldbl-128 -0x4p-1076L : -0x4p-1076L : inexact-ok
= asin upward ldbl-128 -0x4p-1076L : -0x4p-1076L : inexact-ok
-= asin downward ldbl-128ibm -0x4p-1076L : -0x8p-1076L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128ibm -0x4p-1076L : -0x4p-1076L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128ibm -0x4p-1076L : -0x4p-1076L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128ibm -0x4p-1076L : -0x4p-1076L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-96-intel -0x8p-16448L : -0x1p-16444L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-96-intel -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-96-intel -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-96-intel -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-96-m68k -0x8p-16448L : -0xcp-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-96-m68k -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-96-m68k -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-96-m68k -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-128 -0x8p-16448L : -0x8.000000000004p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128 -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128 -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128 -0x8p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-96-m68k -0x4p-16448L : -0x8p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-96-m68k -0x4p-16448L : -0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-96-m68k -0x4p-16448L : -0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-96-m68k -0x4p-16448L : -0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-128 -0x4p-16448L : -0x4.000000000004p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128 -0x4p-16448L : -0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128 -0x4p-16448L : -0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128 -0x4p-16448L : -0x4p-16448L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin downward ldbl-128 -0x4p-16496L : -0x8p-16496L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin tonearest ldbl-128 -0x4p-16496L : -0x4p-16496L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin towardzero ldbl-128 -0x4p-16496L : -0x4p-16496L : inexact-ok underflow underflow-ok errno-erange-ok
-= asin upward ldbl-128 -0x4p-16496L : -0x4p-16496L : inexact-ok underflow underflow-ok errno-erange-ok
+= asin downward ldbl-128ibm -0x4p-1076L : -0x8p-1076L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128ibm -0x4p-1076L : -0x4p-1076L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128ibm -0x4p-1076L : -0x4p-1076L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128ibm -0x4p-1076L : -0x4p-1076L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-96-intel -0x8p-16448L : -0x1p-16444L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-96-intel -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-96-intel -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-96-intel -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-96-m68k -0x8p-16448L : -0xcp-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-96-m68k -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-96-m68k -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-96-m68k -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-128 -0x8p-16448L : -0x8.000000000004p-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128 -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128 -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128 -0x8p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-96-m68k -0x4p-16448L : -0x8p-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-96-m68k -0x4p-16448L : -0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-96-m68k -0x4p-16448L : -0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-96-m68k -0x4p-16448L : -0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-128 -0x4p-16448L : -0x4.000000000004p-16448L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128 -0x4p-16448L : -0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128 -0x4p-16448L : -0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128 -0x4p-16448L : -0x4p-16448L : inexact-ok underflow errno-erange-ok
+= asin downward ldbl-128 -0x4p-16496L : -0x8p-16496L : inexact-ok underflow errno-erange-ok
+= asin tonearest ldbl-128 -0x4p-16496L : -0x4p-16496L : inexact-ok underflow errno-erange-ok
+= asin towardzero ldbl-128 -0x4p-16496L : -0x4p-16496L : inexact-ok underflow errno-erange-ok
+= asin upward ldbl-128 -0x4p-16496L : -0x4p-16496L : inexact-ok underflow errno-erange-ok
asinh 0
= asinh downward flt-32 0x0p+0f : 0x0p+0f : inexact-ok
= asinh tonearest flt-32 0x0p+0f : 0x0p+0f : inexact-ok
diff --git a/sysdeps/i386/fpu/e_asin.S b/sysdeps/i386/fpu/e_asin.S
index 9a44cb6..ea8cb6f 100644
--- a/sysdeps/i386/fpu/e_asin.S
+++ b/sysdeps/i386/fpu/e_asin.S
@@ -7,8 +7,26 @@
RCSID("$NetBSD: e_asin.S,v 1.4 1995/05/08 23:45:40 jtc Exp $")
+ .section .rodata.cst8,"aM",@progbits,8
+
+ .p2align 3
+ .type dbl_min,@object
+dbl_min: .byte 0, 0, 0, 0, 0, 0, 0x10, 0
+ ASM_SIZE_DIRECTIVE(dbl_min)
+
+#ifdef PIC
+# define MO(op) op##@GOTOFF(%ecx)
+#else
+# define MO(op) op
+#endif
+
+ .text
+
/* asin = atan (x / sqrt((1-x) (1+x))) */
ENTRY(__ieee754_asin)
+#ifdef PIC
+ LOAD_PIC_REG (cx)
+#endif
fldl 4(%esp) /* x */
fld %st
fld1 /* 1 : x : x */
@@ -18,6 +36,20 @@ ENTRY(__ieee754_asin)
fmulp /* 1 - x^2 */
fsqrt /* sqrt (1 - x^2) */
fpatan
- ret
+ fldl MO(dbl_min)
+ fld %st(1)
+ fabs
+ fucompp
+ fnstsw
+ sahf
+ jnc 1f
+ subl $8, %esp
+ cfi_adjust_cfa_offset (8)
+ fld %st(0)
+ fmul %st(0)
+ fstpl (%esp)
+ addl $8, %esp
+ cfi_adjust_cfa_offset (-8)
+1: ret
END (__ieee754_asin)
strong_alias (__ieee754_asin, __asin_finite)
diff --git a/sysdeps/i386/fpu/e_asinf.S b/sysdeps/i386/fpu/e_asinf.S
index 5c1065d..f7bda77 100644
--- a/sysdeps/i386/fpu/e_asinf.S
+++ b/sysdeps/i386/fpu/e_asinf.S
@@ -8,8 +8,26 @@
RCSID("$NetBSD: $")
+ .section .rodata.cst4,"aM",@progbits,4
+
+ .p2align 2
+ .type flt_min,@object
+flt_min: .byte 0, 0, 0x80, 0
+ ASM_SIZE_DIRECTIVE(flt_min)
+
+#ifdef PIC
+# define MO(op) op##@GOTOFF(%ecx)
+#else
+# define MO(op) op
+#endif
+
+ .text
+
/* asin = atan (x / sqrt(1 - x^2)) */
ENTRY(__ieee754_asinf)
+#ifdef PIC
+ LOAD_PIC_REG (cx)
+#endif
flds 4(%esp) /* x */
fld %st
fmul %st(0) /* x^2 */
@@ -17,6 +35,20 @@ ENTRY(__ieee754_asinf)
fsubp /* 1 - x^2 */
fsqrt /* sqrt (1 - x^2) */
fpatan
- ret
+ flds MO(flt_min)
+ fld %st(1)
+ fabs
+ fucompp
+ fnstsw
+ sahf
+ jnc 1f
+ subl $4, %esp
+ cfi_adjust_cfa_offset (4)
+ fld %st(0)
+ fmul %st(0)
+ fstps (%esp)
+ addl $4, %esp
+ cfi_adjust_cfa_offset (-4)
+1: ret
END (__ieee754_asinf)
strong_alias (__ieee754_asinf, __asinf_finite)
diff --git a/sysdeps/ieee754/dbl-64/e_asin.c b/sysdeps/ieee754/dbl-64/e_asin.c
index e90f47c..b87e557 100644
--- a/sysdeps/ieee754/dbl-64/e_asin.c
+++ b/sysdeps/ieee754/dbl-64/e_asin.c
@@ -39,6 +39,8 @@
#include "powtwo.tbl"
#include "MathLib.h"
#include "uasncs.h"
+#include <float.h>
+#include <math.h>
#include <math_private.h>
#ifndef SECTION
@@ -67,7 +69,15 @@ __ieee754_asin(double x){
m = u.i[HIGH_HALF];
k = 0x7fffffff&m; /* no sign */
- if (k < 0x3e500000) return x; /* for x->0 => sin(x)=x */
+ if (k < 0x3e500000)
+ {
+ if (fabs (x) < DBL_MIN)
+ {
+ double force_underflow = x * x;
+ math_force_eval (force_underflow);
+ }
+ return x; /* for x->0 => sin(x)=x */
+ }
/*----------------------2^-26 <= |x| < 2^ -3 -----------------*/
else
if (k < 0x3fc00000) {
diff --git a/sysdeps/ieee754/flt-32/e_asinf.c b/sysdeps/ieee754/flt-32/e_asinf.c
index 91ca9af..00bad42 100644
--- a/sysdeps/ieee754/flt-32/e_asinf.c
+++ b/sysdeps/ieee754/flt-32/e_asinf.c
@@ -39,6 +39,7 @@
static char rcsid[] = "$NetBSD: e_asinf.c,v 1.5 1995/05/12 04:57:25 jtc Exp $";
#endif
+#include <float.h>
#include <math.h>
#include <math_private.h>
@@ -72,6 +73,11 @@ float __ieee754_asinf(float x)
return (x-x)/(x-x); /* asin(|x|>1) is NaN */
} else if (ix<0x3f000000) { /* |x|<0.5 */
if(ix<0x32000000) { /* if |x| < 2**-27 */
+ if (fabsf (x) < FLT_MIN)
+ {
+ float force_underflow = x * x;
+ math_force_eval (force_underflow);
+ }
if(huge+x>one) return x;/* return x with inexact if x!=0*/
} else {
t = x*x;
diff --git a/sysdeps/ieee754/ldbl-128/e_asinl.c b/sysdeps/ieee754/ldbl-128/e_asinl.c
index cd1a8da..353603d 100644
--- a/sysdeps/ieee754/ldbl-128/e_asinl.c
+++ b/sysdeps/ieee754/ldbl-128/e_asinl.c
@@ -59,6 +59,7 @@
*/
+#include <float.h>
#include <math.h>
#include <math_private.h>
long double sqrtl (long double);
@@ -152,6 +153,11 @@ __ieee754_asinl (long double x)
{
if (ix < 0x3fc60000) /* |x| < 2**-57 */
{
+ if (fabsl (x) < LDBL_MIN)
+ {
+ long double force_underflow = x * x;
+ math_force_eval (force_underflow);
+ }
if (huge + x > one)
return x; /* return x with inexact if x!=0 */
}
diff --git a/sysdeps/ieee754/ldbl-128ibm/e_asinl.c b/sysdeps/ieee754/ldbl-128ibm/e_asinl.c
index dece118..00386db 100644
--- a/sysdeps/ieee754/ldbl-128ibm/e_asinl.c
+++ b/sysdeps/ieee754/ldbl-128ibm/e_asinl.c
@@ -59,6 +59,7 @@
*/
+#include <float.h>
#include <math.h>
#include <math_private.h>
long double sqrtl (long double);
@@ -146,6 +147,11 @@ __ieee754_asinl (long double x)
{
if (a < 6.938893903907228e-18L) /* |x| < 2**-57 */
{
+ if (fabsl (x) < LDBL_MIN)
+ {
+ long double force_underflow = x * x;
+ math_force_eval (force_underflow);
+ }
if (huge + x > one)
return x; /* return x with inexact if x!=0 */
}
diff --git a/sysdeps/ieee754/ldbl-96/e_asinl.c b/sysdeps/ieee754/ldbl-96/e_asinl.c
index c1ffa3e..2973bf0 100644
--- a/sysdeps/ieee754/ldbl-96/e_asinl.c
+++ b/sysdeps/ieee754/ldbl-96/e_asinl.c
@@ -58,6 +58,7 @@
*/
+#include <float.h>
#include <math.h>
#include <math_private.h>
@@ -111,6 +112,11 @@ __ieee754_asinl (long double x)
{ /* |x|<0.5 */
if (ix < 0x3fde8000)
{ /* if |x| < 2**-33 */
+ if (fabsl (x) < LDBL_MIN)
+ {
+ long double force_underflow = x * x;
+ math_force_eval (force_underflow);
+ }
if (huge + x > one)
return x; /* return x with inexact if x!=0 */
}
diff --git a/sysdeps/x86_64/fpu/multiarch/e_asin.c b/sysdeps/x86_64/fpu/multiarch/e_asin.c
index e742a9c..55865c0 100644
--- a/sysdeps/x86_64/fpu/multiarch/e_asin.c
+++ b/sysdeps/x86_64/fpu/multiarch/e_asin.c
@@ -1,5 +1,6 @@
#ifdef HAVE_FMA4_SUPPORT
# include <init-arch.h>
+# include <math.h>
# include <math_private.h>
extern double __ieee754_acos_sse2 (double);