From 9bd3ef8e19b19fb3cfcf99a33a1493035891b990 Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Wed, 8 Jun 2016 21:55:06 +0000 Subject: Fix i386/x86_64 expl, exp10l, expm1l for sNaN input (bug 20226). The i386 and x86_64 implementations of expl, exp10l and expm1l (code shared between the functions) return sNaN for sNaN input. This patch fixes them to add NaN inputs to themselves so that qNaN is returned in this case. Tested for x86_64 and x86. [BZ #20226] * sysdeps/i386/fpu/e_expl.S (IEEE754_EXPL): Add NaN argument to itself. * sysdeps/x86_64/fpu/e_expl.S (IEEE754_EXPL): Likewise. * math/libm-test.inc (exp_test_data): Add sNaN tests. (exp10_test_data): Likewise. (expm1_test_data): Likewise. --- ChangeLog | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index cf5e480bbf..0d140aab66 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,13 @@ 2016-06-08 Joseph Myers + [BZ #20226] + * sysdeps/i386/fpu/e_expl.S (IEEE754_EXPL): Add NaN argument to + itself. + * sysdeps/x86_64/fpu/e_expl.S (IEEE754_EXPL): Likewise. + * math/libm-test.inc (exp_test_data): Add sNaN tests. + (exp10_test_data): Likewise. + (expm1_test_data): Likewise. + [BZ #20225] * math/s_ldexp.c (__ldexp): Add non-finite or zero argument to itself. -- cgit 1.4.1