From 4060283decf711ed95a6c4993ffeaba39f8cd40a Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Tue, 24 Jun 2014 21:00:08 +0000 Subject: Fix x86/x86_64 expm1l spurious underflow exceptions (bug 16539). This patch fixes bug 16539, spurious underflow exceptions from x86 / x86-64 expm1l. The problem is that the computation of a base-2 exponent with extra precision involves spurious underflows for arguments that are small but not subnormal, so a check is added to just return the argument in those cases. (If the argument *is* subnormal, underflowing is correct and the existing code will always underflow, so it suffices to keep using the existing code in that case; some expm1 implementations have a bug (bug 16353) with missing underflow exceptions, but I don't think there's such a bug in this particular version.) Tested x86_64 and x86; no ulps updates needed. (auto-libm-test-out diffs omitted below.) [BZ #16539] * sysdeps/i386/fpu/e_expl.S (IEEE754_EXPL) [USE_AS_EXPM1L]: Just return the argument for normal arguments with exponent below -64. * sysdeps/x86_64/fpu/e_expl.S (IEEE754_EXPL) [USE_AS_EXPM1L]: Likewise. * math/auto-libm-test-in: Add another test of expm1. * math/auto-libm-test-out: Regenerated. --- ChangeLog | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index 8ddb74fff6..ce6c4d8f24 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,13 @@ 2014-06-24 Joseph Myers + [BZ #16539] + * sysdeps/i386/fpu/e_expl.S (IEEE754_EXPL) [USE_AS_EXPM1L]: Just + return the argument for normal arguments with exponent below -64. + * sysdeps/x86_64/fpu/e_expl.S (IEEE754_EXPL) [USE_AS_EXPM1L]: + Likewise. + * math/auto-libm-test-in: Add another test of expm1. + * math/auto-libm-test-out: Regenerated. + [BZ #16287] * sysdeps/ieee754/ldbl-128/s_erfl.c (__erfl): Return 1 without calling __erfcl for arguments at least 16. -- cgit 1.4.1