Add further tests of libm functions.

This patch adds more randomly-generated tests of various libm
functions that are observed to increase ulps on x86_64.  (This process
must eventually converge, when my random test generation stops finding
inputs that increase the listed ulps, except maybe for any cases
uncovered where the errors exceed the maximum allowed 9ulp error and
so indicate actual libm bugs needing fixing.)

Tested for x86_64 and x86 and ulps updated accordingly.

	* math/auto-libm-test-in: Add more tests of acosh, atanh, clog,
	clog10, csqrt, erfc, exp2, expm1, log10, log2 and sinh.
	* math/auto-libm-test-out: Regenerated.
	* sysdeps/i386/fpu/libm-test-ulps: Update.
	* sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
This commit is contained in:
Joseph Myers 2015-05-05 22:59:41 +00:00
parent a6ab6ccda3
commit 31450d9a87
5 changed files with 2927 additions and 75 deletions

View File

@ -1,3 +1,11 @@
2015-05-05 Joseph Myers <joseph@codesourcery.com>
* math/auto-libm-test-in: Add more tests of acosh, atanh, clog,
clog10, csqrt, erfc, exp2, expm1, log10, log2 and sinh.
* math/auto-libm-test-out: Regenerated.
* sysdeps/i386/fpu/libm-test-ulps: Update.
* sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-04-30 Daniel Marjamäki <daniel.marjamaki@evidente.se>
[BZ #18265]

View File

@ -114,6 +114,7 @@ acosh 0x1p5000
acosh 0x1.80a368p+0
acosh 0x1.0b9d3e9fc19fbp+0
acosh 0x1.11eab6p+0
acosh 0x1.0fffaap+0
acosh max no-test-inline
asin 0
@ -376,6 +377,7 @@ atanh 0x3.dfb1f5db0ceccp-4
atanh 0x2.251b2a64c85dep-4
atanh -0x2.e3458cp-4
atanh 0x3.91d9f3c80c72d7acp-4
atanh -0x2.6c52c26567198p-4
# Bug 16352: underflow exception may be missing.
atanh 0x1p-500 missing-underflow
atanh 0x1p-5000 missing-underflow
@ -574,6 +576,11 @@ clog -0x9.93d164127d9fp-4 0x7.c5c8d8p-4
clog -0xa.5920ap-4 -0x6.2cda5p-4
clog 0xd.d05c38ebb1b4p+60 -0x3.c22fdp+44
clog -0xa.19f8ec252c58d5p-4 0x7.d10cdec29a141538p-4
clog -0xa.7ac41a0b417cb8fp-4 -0x6.c5a32eaeedd4p-4
clog 0x3.c16p-136 0x8p-152
clog -0x1.0a69de710590dp+0 -0x7.bc7e121e2b0d1088p-4
clog 0x1.fffffep+127 0x1.fffffep+127
clog 0x1.fffffep+127 1.0
clog 0x1p-149 0x1p-149
@ -717,6 +724,11 @@ clog10 -0x9.93d164127d9fp-4 0x7.c5c8d8p-4
clog10 -0xa.5920ap-4 -0x6.2cda5p-4
clog10 0xd.d05c38ebb1b4p+60 -0x3.c22fdp+44
clog10 -0xa.19f8ec252c58d5p-4 0x7.d10cdec29a141538p-4
clog10 -0xa.7ac41a0b417cb8fp-4 -0x6.c5a32eaeedd4p-4
clog10 0x3.c16p-136 0x8p-152
clog10 -0x1.0a69de710590dp+0 -0x7.bc7e121e2b0d1088p-4
clog10 0x1.fffffep+127 0x1.fffffep+127
clog10 0x1.fffffep+127 1.0
clog10 0x1p-149 0x1p-149
@ -966,6 +978,9 @@ csqrt -0x4.15ca1p+0 -0x8p-152
csqrt 0xf.a24adp+28 0x8.0f148p+36
csqrt 0x1.f9610ap+4 0x9.87716p+4
csqrt 0x5.9cc21p-4 -0x1.fb1ec91b40dcdp+0
csqrt -0x7.31291c9fdae04p-160 -0x8p-152
csqrt 0x1.d60caep+0 0x7.a7d468p+0
csqrt -0xb.e2bc1cd6eaa7p-180 0x8p-152
csqrt 0x1.fffffep+127 0x1.fffffep+127
csqrt 0x1.fffffep+127 1.0
@ -1141,6 +1156,7 @@ erfc 0xb.227499103357d84p+0
erfc 0xd.28abfp-4
erfc 0x1.5289fep+0
erfc 0x4.b48498p+0
erfc 0x2.f8646cp+0
exp 0
exp -0
@ -1275,6 +1291,8 @@ exp2 -0x1.567cc8p+0
exp2 -0x1.bbbd76p+0
exp2 -0x1.3045fep+8
exp2 0xa.87b8bp+0
exp2 -0xe.2ce69p-4
exp2 -0xc.1bf12p-16
expm1 0
expm1 -0
@ -1330,6 +1348,7 @@ expm1 0x6.660247486aed8p-4
expm1 0x6.289a78p-4
expm1 0x6.1b4d318238d4a2a8p-4
expm1 0x5.fb8dc64e91a74p-4
expm1 0x3.735f497c4e67535cp-4
# Bug 16353: underflow exception may be missing
expm1 0x4.0000000000000028p-16384 missing-underflow
@ -1815,6 +1834,7 @@ log10 0x1.7163aep+0
log10 0xa.9d0d4p-4
log10 0x1.251ec6p+0
log10 0x1.022e82p+0
log10 0x9.b3727e3feb538p-4
log1p 0
log1p -0
@ -1860,6 +1880,7 @@ log2 0x1.07465bdc7e41b52ep+0
log2 0xf.4dfb4p-48
log2 0x1.0a588ep+0
log2 0xb.e77c6p-4
log2 0x1.4fe37ep+0
log2 min
log2 min_subnorm
@ -2306,6 +2327,8 @@ sinh -0x3.ca68c96337692p-4
sinh -0x3.92da05a85024b314p-4
sinh -0x3.3e6292ed442d450cp-4
sinh 0x7.6e259d2436fc4p-4
sinh 0x3.d6e088p-4
sinh -0x7.688eap-4
sqrt 0
sqrt -0

File diff suppressed because it is too large Load Diff

View File

@ -157,7 +157,7 @@ Function: "atanh_upward":
idouble: 1
ifloat: 1
ildouble: 5
ldouble: 4
ldouble: 5
Function: "cabs":
ildouble: 1
@ -742,12 +742,12 @@ ildouble: 1
ldouble: 1
Function: Real part of "clog":
double: 2
double: 3
float: 2
idouble: 2
idouble: 3
ifloat: 2
ildouble: 3
ldouble: 3
ildouble: 4
ldouble: 4
Function: Imaginary part of "clog":
double: 1
@ -770,12 +770,12 @@ ildouble: 2
ldouble: 2
Function: Real part of "clog10_downward":
double: 4
double: 5
float: 4
idouble: 4
idouble: 5
ifloat: 4
ildouble: 7
ldouble: 7
ildouble: 8
ldouble: 8
Function: Imaginary part of "clog10_downward":
double: 1
@ -786,12 +786,12 @@ ildouble: 2
ldouble: 2
Function: Real part of "clog10_towardzero":
double: 4
double: 5
float: 4
idouble: 4
idouble: 5
ifloat: 4
ildouble: 7
ldouble: 7
ildouble: 8
ldouble: 8
Function: Imaginary part of "clog10_towardzero":
double: 1
@ -802,10 +802,10 @@ ildouble: 3
ldouble: 3
Function: Real part of "clog10_upward":
double: 4
float: 4
idouble: 4
ifloat: 4
double: 5
float: 5
idouble: 5
ifloat: 5
ildouble: 6
ldouble: 6
@ -818,12 +818,12 @@ ildouble: 3
ldouble: 3
Function: Real part of "clog_downward":
double: 4
double: 5
float: 5
idouble: 4
idouble: 5
ifloat: 5
ildouble: 5
ldouble: 5
ildouble: 7
ldouble: 7
Function: Imaginary part of "clog_downward":
double: 1
@ -834,12 +834,12 @@ ildouble: 1
ldouble: 1
Function: Real part of "clog_towardzero":
double: 4
double: 5
float: 5
idouble: 4
idouble: 5
ifloat: 5
ildouble: 5
ldouble: 5
ildouble: 8
ldouble: 8
Function: Imaginary part of "clog_towardzero":
double: 1
@ -1108,8 +1108,8 @@ ildouble: 2
ldouble: 2
Function: Imaginary part of "csqrt":
ildouble: 1
ldouble: 1
ildouble: 2
ldouble: 2
Function: Real part of "csqrt_downward":
double: 1
@ -1128,8 +1128,8 @@ ldouble: 3
Function: Real part of "csqrt_towardzero":
double: 1
idouble: 1
ildouble: 3
ldouble: 3
ildouble: 4
ldouble: 4
Function: Imaginary part of "csqrt_towardzero":
double: 1
@ -1422,8 +1422,8 @@ double: 1
float: 1
idouble: 1
ifloat: 1
ildouble: 3
ldouble: 3
ildouble: 4
ldouble: 4
Function: "expm1_upward":
double: 1

View File

@ -48,9 +48,9 @@ ildouble: 4
ldouble: 4
Function: "acosh_towardzero":
double: 1
double: 2
float: 1
idouble: 1
idouble: 2
ifloat: 1
ildouble: 4
ldouble: 4
@ -214,8 +214,8 @@ double: 2
float: 3
idouble: 2
ifloat: 3
ildouble: 4
ldouble: 4
ildouble: 5
ldouble: 5
Function: "cabs":
double: 1
@ -818,12 +818,12 @@ ildouble: 1
ldouble: 1
Function: Real part of "clog":
double: 2
double: 3
float: 2
idouble: 2
idouble: 3
ifloat: 2
ildouble: 3
ldouble: 3
ildouble: 4
ldouble: 4
Function: Imaginary part of "clog":
float: 1
@ -852,24 +852,24 @@ double: 6
float: 6
idouble: 6
ifloat: 6
ildouble: 7
ldouble: 7
ildouble: 8
ldouble: 8
Function: Imaginary part of "clog10_downward":
double: 2
float: 3
float: 4
idouble: 2
ifloat: 3
ifloat: 4
ildouble: 2
ldouble: 2
Function: Real part of "clog10_towardzero":
double: 4
double: 5
float: 4
idouble: 4
idouble: 5
ifloat: 4
ildouble: 7
ldouble: 7
ildouble: 8
ldouble: 8
Function: Imaginary part of "clog10_towardzero":
double: 2
@ -880,9 +880,9 @@ ildouble: 3
ldouble: 3
Function: Real part of "clog10_upward":
double: 7
double: 8
float: 5
idouble: 7
idouble: 8
ifloat: 5
ildouble: 6
ldouble: 6
@ -896,12 +896,12 @@ ildouble: 3
ldouble: 3
Function: Real part of "clog_downward":
double: 4
double: 7
float: 5
idouble: 4
idouble: 7
ifloat: 5
ildouble: 5
ldouble: 5
ildouble: 7
ldouble: 7
Function: Imaginary part of "clog_downward":
double: 1
@ -916,8 +916,8 @@ double: 7
float: 5
idouble: 7
ifloat: 5
ildouble: 5
ldouble: 5
ildouble: 8
ldouble: 8
Function: Imaginary part of "clog_towardzero":
double: 1
@ -928,9 +928,9 @@ ildouble: 1
ldouble: 1
Function: Real part of "clog_upward":
double: 5
double: 8
float: 5
idouble: 5
idouble: 8
ifloat: 5
ildouble: 6
ldouble: 6
@ -1188,8 +1188,8 @@ double: 2
float: 2
idouble: 2
ifloat: 2
ildouble: 1
ldouble: 1
ildouble: 2
ldouble: 2
Function: Real part of "csqrt_downward":
double: 4
@ -1212,8 +1212,8 @@ double: 3
float: 3
idouble: 3
ifloat: 3
ildouble: 3
ldouble: 3
ildouble: 4
ldouble: 4
Function: Imaginary part of "csqrt_towardzero":
double: 3
@ -1224,9 +1224,9 @@ ildouble: 3
ldouble: 3
Function: Real part of "csqrt_upward":
double: 4
double: 5
float: 4
idouble: 4
idouble: 5
ifloat: 4
ildouble: 4
ldouble: 4
@ -1417,9 +1417,9 @@ ldouble: 4
Function: "erfc_towardzero":
double: 3
float: 3
float: 4
idouble: 3
ifloat: 3
ifloat: 4
ildouble: 4
ldouble: 4
@ -1474,17 +1474,25 @@ ildouble: 1
ldouble: 1
Function: "exp2_downward":
double: 1
float: 1
idouble: 1
ifloat: 1
ildouble: 1
ldouble: 1
Function: "exp2_towardzero":
double: 1
float: 1
idouble: 1
ifloat: 1
ildouble: 1
ldouble: 1
Function: "exp2_upward":
double: 1
float: 1
idouble: 1
ifloat: 1
ildouble: 1
ldouble: 1
@ -1528,8 +1536,8 @@ double: 1
float: 1
idouble: 1
ifloat: 1
ildouble: 3
ldouble: 3
ildouble: 4
ldouble: 4
Function: "expm1_upward":
double: 1
@ -1706,9 +1714,9 @@ ildouble: 1
ldouble: 1
Function: "log10":
double: 1
double: 2
float: 2
idouble: 1
idouble: 2
ifloat: 2
ildouble: 1
ldouble: 1
@ -1770,9 +1778,9 @@ ildouble: 3
ldouble: 3
Function: "log2":
double: 1
double: 2
float: 1
idouble: 1
idouble: 2
ifloat: 1
ildouble: 1
ldouble: 1
@ -1925,9 +1933,9 @@ ldouble: 2
Function: "sinh":
double: 1
float: 1
float: 2
idouble: 1
ifloat: 1
ifloat: 2
ildouble: 2
ldouble: 2
@ -1948,9 +1956,9 @@ ildouble: 4
ldouble: 4
Function: "sinh_upward":
double: 2
double: 3
float: 3
idouble: 2
idouble: 3
ifloat: 3
ildouble: 5
ldouble: 5