From patchwork Sat May 2 21:07:28 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 467344 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 9AEF31402B4 for ; Sun, 3 May 2015 07:07:45 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass reason="1024-bit key; unprotected key" header.d=sourceware.org header.i=@sourceware.org header.b=nbosgSGA; dkim-adsp=none (unprotected policy); dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:mime-version :content-type; q=dns; s=default; b=rgfv24V4+lWz0HJpTyRn8Q/nU2YA/ nOCmGgXdlrSCtQ3SZREkgL/+FC8R0LCismDGiiH99cniz2X3sVgIspeysD/w8c9/ rE5qbd3sBqo5y+hpOhmlBTFEAt/3gG+TeoYX1CvhRL+RRk2CXGuzcGTqIlo70UOj MXrQd6lwnHYOvE= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:mime-version :content-type; s=default; bh=Zm3Y88T089MyjJd6/wECwzGrE9o=; b=nbo sgSGAs0t520qTG/J30IhAp2uJyjAix1wcBtGHjOLH4gv5ucQsxRhXaCNFVdN1o8t QEFN5znwU6dqeenGJE9YtWi5y46Y70uI8ppSdaF8h9DqjlNwAXoMcxV0z+DLPPCq qghYQScDnk8J9GeC11bD+szf8XohW2csV2TV+5MA= Received: (qmail 78767 invoked by alias); 2 May 2015 21:07:39 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 78750 invoked by uid 89); 2 May 2015 21:07:37 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.9 required=5.0 tests=AWL, BAYES_50, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 X-HELO: relay1.mentorg.com Date: Sat, 2 May 2015 21:07:28 +0000 From: Joseph Myers To: Subject: Add more tests of libm functions [committed] Message-ID: User-Agent: Alpine 2.10 (DEB 1266 2009-07-14) MIME-Version: 1.0 This patch adds more randomly-generated tests of various libm functions that are observed to increase ulps on x86_64. Tested for x86_64 and x86 and ulps updated accordingly. Committed. (auto-libm-test-out diffs omitted below.) 2015-05-02 Joseph Myers * math/auto-libm-test-in: Add more tests of atan, clog, clog10, cos, csqrt, erf, erfc, exp2, lgamma, log1p, sin, sincos, tanh and tgamma. * math/auto-libm-test-out: Regenerated. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise. diff --git a/math/auto-libm-test-in b/math/auto-libm-test-in index 89fcc17..6cad94d 100644 --- a/math/auto-libm-test-in +++ b/math/auto-libm-test-in @@ -245,6 +245,7 @@ atan -0x3.3fb708p-4 atan -0x2.3249ap+0 atan -0x1.363f46p+0 atan -0x1.ad4c0ap+0 +atan -0x3.eb8e18p+0 atan min atan -min atan min_subnorm @@ -569,6 +570,10 @@ clog 0x6.9a4569067b6ecp-4 0xb.0a30d15e7d798p-4 clog -0x1.105436p+0 -0x6.66396df3cc7ap-4 clog -0x2.c90b952282392dep-4 0x1.43cda16634cc7046p+0 +clog -0x9.93d164127d9fp-4 0x7.c5c8d8p-4 +clog -0xa.5920ap-4 -0x6.2cda5p-4 +clog 0xd.d05c38ebb1b4p+60 -0x3.c22fdp+44 + clog 0x1.fffffep+127 0x1.fffffep+127 clog 0x1.fffffep+127 1.0 clog 0x1p-149 0x1p-149 @@ -708,6 +713,10 @@ clog10 -0x2.51320d99da5a2p-4 0x3.b8176p-4 clog10 -0x1.25c2d3e172df8p+0 0 clog10 0x1.0c684e35d0b2ap+0 -0x7.37df8a65c28fp-4 +clog10 -0x9.93d164127d9fp-4 0x7.c5c8d8p-4 +clog10 -0xa.5920ap-4 -0x6.2cda5p-4 +clog10 0xd.d05c38ebb1b4p+60 -0x3.c22fdp+44 + clog10 0x1.fffffep+127 0x1.fffffep+127 clog10 0x1.fffffep+127 1.0 clog10 0x1p-149 0x1p-149 @@ -866,6 +875,7 @@ cos -min cos min_subnorm cos -min_subnorm cos -0x3.3de320f6be87ep+1020 +cos 0xe.9f1e5bc3bb88p+112 cosh 0 cosh -0 @@ -954,6 +964,8 @@ csqrt -0x4.82773b736291p-4 -0x1.bcb7cep+0 csqrt 0xf.fffffp+124 0xe.7e0c2p+116 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 0x1.fffffep+127 0x1.fffffep+127 csqrt 0x1.fffffep+127 1.0 @@ -1091,6 +1103,7 @@ erf max erf -0x1.ddaea4p+0 erf -0x1.2b1f68p+0 erf 0x1.44e722p+0 +erf -0x1.3a0d48p+0 erfc 0.0 erfc -0 @@ -1125,6 +1138,9 @@ erfc 0x8.c66b44ca40038p+0 erfc 0x2.586f1cp+0 erfc 0xb.acb72p+0 erfc 0xb.227499103357d84p+0 +erfc 0xd.28abfp-4 +erfc 0x1.5289fep+0 +erfc 0x4.b48498p+0 exp 0 exp -0 @@ -1258,6 +1274,7 @@ exp2 0xc.122c4p-4 exp2 -0x1.567cc8p+0 exp2 -0x1.bbbd76p+0 exp2 -0x1.3045fep+8 +exp2 0xa.87b8bp+0 expm1 0 expm1 -0 @@ -1767,6 +1784,7 @@ lgamma 0xa.d55d6b4d78e28p+0 lgamma 0x8.d6315p+0 lgamma 0xb.2e679p+0 lgamma 0xb.01191p+0 +lgamma 0xb.26fdap+0 log 1 log e @@ -1826,6 +1844,7 @@ log1p 0x7.89dc17790eeb4p-4 log1p 0x9.81ccf8887c24a7bp-4 log1p 0xa.5028608bd65f38dp-4 log1p 0x5.bf78873e20a2d468p-4 +log1p 0x7.aa5198p-4 log2 1 log2 e @@ -2243,6 +2262,7 @@ sin 9 sin 10 sin 0x1.2001469775ce6p32 sin -0x3.3de320f6be87ep+1020 +sin 0xe.9f1e5bc3bb88p+112 sincos 0 sincos -0 @@ -2263,6 +2283,7 @@ sincos 0x1.fffffep+127 sincos 0x1p+50 sincos 0x1p+28 sincos -0x3.3de320f6be87ep+1020 +sincos 0xe.9f1e5bc3bb88p+112 sinh 0 sinh -0 @@ -2428,6 +2449,7 @@ tanh 0x7.a18e8p-4 tanh -0x2.6082fp-4 tanh 0xe.05031p-16 tanh 0x3.c80eaa7adaa3p-4 +tanh 0x2.00f9857616524p-4 tgamma 0.5 tgamma -0.5 @@ -2873,6 +2895,7 @@ tgamma -100000.5 tgamma -0x3.06644cp+0 tgamma -0x6.fe4636e0c5064p+0 tgamma -0x7.a13d7a2945cd5718p+0 +tgamma -0x1.4a5caap+4 y0 0.125 y0 0.75 diff --git a/sysdeps/i386/fpu/libm-test-ulps b/sysdeps/i386/fpu/libm-test-ulps index 2eceadf..29930c3 100644 --- a/sysdeps/i386/fpu/libm-test-ulps +++ b/sysdeps/i386/fpu/libm-test-ulps @@ -771,9 +771,9 @@ ldouble: 2 Function: Real part of "clog10_downward": double: 4 -float: 3 +float: 4 idouble: 4 -ifloat: 3 +ifloat: 4 ildouble: 7 ldouble: 7 @@ -787,9 +787,9 @@ ldouble: 2 Function: Real part of "clog10_towardzero": double: 4 -float: 3 +float: 4 idouble: 4 -ifloat: 3 +ifloat: 4 ildouble: 7 ldouble: 7 @@ -798,8 +798,8 @@ double: 1 float: 1 idouble: 1 ifloat: 1 -ildouble: 2 -ldouble: 2 +ildouble: 3 +ldouble: 3 Function: Real part of "clog10_upward": double: 4 @@ -814,8 +814,8 @@ double: 1 float: 1 idouble: 1 ifloat: 1 -ildouble: 2 -ldouble: 2 +ildouble: 3 +ldouble: 3 Function: Real part of "clog_downward": double: 4 @@ -872,8 +872,8 @@ ldouble: 1 Function: "cos_downward": double: 1 idouble: 1 -ildouble: 2 -ldouble: 2 +ildouble: 3 +ldouble: 3 Function: "cos_towardzero": double: 1 @@ -1328,8 +1328,8 @@ double: 1 float: 2 idouble: 1 ifloat: 2 -ildouble: 3 -ldouble: 3 +ildouble: 4 +ldouble: 4 Function: "erfc_upward": double: 2 @@ -1766,8 +1766,8 @@ ldouble: 1 Function: "sincos_downward": double: 1 idouble: 1 -ildouble: 2 -ldouble: 2 +ildouble: 3 +ldouble: 3 Function: "sincos_towardzero": double: 1 @@ -1838,8 +1838,8 @@ double: 1 float: 1 idouble: 1 ifloat: 1 -ildouble: 4 -ldouble: 3 +ildouble: 5 +ldouble: 4 Function: "tanh_towardzero": double: 1 diff --git a/sysdeps/x86_64/fpu/libm-test-ulps b/sysdeps/x86_64/fpu/libm-test-ulps index 97e279c..996251e 100644 --- a/sysdeps/x86_64/fpu/libm-test-ulps +++ b/sysdeps/x86_64/fpu/libm-test-ulps @@ -163,9 +163,9 @@ ldouble: 1 Function: "atan_downward": double: 1 -float: 1 +float: 2 idouble: 1 -ifloat: 1 +ifloat: 2 ildouble: 1 ldouble: 1 @@ -833,9 +833,9 @@ ldouble: 1 Function: Real part of "clog10": double: 3 -float: 2 +float: 3 idouble: 3 -ifloat: 2 +ifloat: 3 ildouble: 4 ldouble: 4 @@ -849,9 +849,9 @@ ldouble: 2 Function: Real part of "clog10_downward": double: 6 -float: 5 +float: 6 idouble: 6 -ifloat: 5 +ifloat: 6 ildouble: 7 ldouble: 7 @@ -865,9 +865,9 @@ ldouble: 2 Function: Real part of "clog10_towardzero": double: 4 -float: 3 +float: 4 idouble: 4 -ifloat: 3 +ifloat: 4 ildouble: 7 ldouble: 7 @@ -876,13 +876,13 @@ double: 2 float: 4 idouble: 2 ifloat: 4 -ildouble: 2 -ldouble: 2 +ildouble: 3 +ldouble: 3 Function: Real part of "clog10_upward": -double: 6 +double: 7 float: 5 -idouble: 6 +idouble: 7 ifloat: 5 ildouble: 6 ldouble: 6 @@ -892,8 +892,8 @@ double: 2 float: 3 idouble: 2 ifloat: 3 -ildouble: 2 -ldouble: 2 +ildouble: 3 +ldouble: 3 Function: Real part of "clog_downward": double: 4 @@ -950,8 +950,8 @@ ldouble: 1 Function: "cos_downward": double: 1 idouble: 1 -ildouble: 2 -ldouble: 2 +ildouble: 3 +ldouble: 3 Function: "cos_towardzero": double: 1 @@ -1184,10 +1184,10 @@ ildouble: 2 ldouble: 2 Function: Imaginary part of "csqrt": -double: 1 -float: 1 -idouble: 1 -ifloat: 1 +double: 2 +float: 2 +idouble: 2 +ifloat: 2 ildouble: 1 ldouble: 1 @@ -1392,7 +1392,9 @@ ildouble: 1 ldouble: 1 Function: "erf_upward": +double: 1 float: 1 +idouble: 1 ifloat: 1 ildouble: 1 ldouble: 1 @@ -1406,10 +1408,10 @@ ildouble: 2 ldouble: 2 Function: "erfc_downward": -double: 3 -float: 5 -idouble: 3 -ifloat: 5 +double: 4 +float: 6 +idouble: 4 +ifloat: 6 ildouble: 4 ldouble: 4 @@ -1418,8 +1420,8 @@ double: 3 float: 3 idouble: 3 ifloat: 3 -ildouble: 3 -ldouble: 3 +ildouble: 4 +ldouble: 4 Function: "erfc_upward": double: 4 @@ -1476,6 +1478,8 @@ ildouble: 1 ldouble: 1 Function: "exp2_towardzero": +float: 1 +ifloat: 1 ildouble: 1 ldouble: 1 @@ -1560,9 +1564,9 @@ ildouble: 5 ldouble: 5 Function: "gamma_upward": -double: 3 +double: 4 float: 3 -idouble: 3 +idouble: 4 ifloat: 3 ildouble: 4 ldouble: 4 @@ -1688,9 +1692,9 @@ ildouble: 5 ldouble: 5 Function: "lgamma_upward": -double: 3 +double: 4 float: 3 -idouble: 3 +idouble: 4 ifloat: 3 ildouble: 4 ldouble: 4 @@ -1743,9 +1747,9 @@ ldouble: 2 Function: "log1p_downward": double: 2 -float: 1 +float: 2 idouble: 2 -ifloat: 1 +ifloat: 2 ildouble: 3 ldouble: 3 @@ -1904,8 +1908,8 @@ ldouble: 1 Function: "sincos_downward": double: 1 idouble: 1 -ildouble: 2 -ldouble: 2 +ildouble: 3 +ldouble: 3 Function: "sincos_towardzero": double: 1 @@ -1994,8 +1998,8 @@ double: 3 float: 3 idouble: 3 ifloat: 3 -ildouble: 3 -ldouble: 3 +ildouble: 4 +ldouble: 4 Function: "tanh_towardzero": double: 2 @@ -2015,9 +2019,9 @@ ldouble: 4 Function: "tgamma": double: 9 -float: 4 +float: 5 idouble: 9 -ifloat: 4 +ifloat: 5 ildouble: 6 ldouble: 6