about summary refs log tree commit diff
path: root/ChangeLog
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2016-10-19 22:58:34 +0000
committerJoseph Myers <joseph@codesourcery.com>2016-10-19 22:58:34 +0000
commit05f3ed0a799d08c2b3ecc256fc0dc08d8b9a3784 (patch)
tree1904f26eb95916cec76cb876dbe163bb72593235 /ChangeLog
parentf8e8b8ed9f266097b42a77359445372d82365916 (diff)
downloadglibc-05f3ed0a799d08c2b3ecc256fc0dc08d8b9a3784.tar.gz
glibc-05f3ed0a799d08c2b3ecc256fc0dc08d8b9a3784.tar.xz
glibc-05f3ed0a799d08c2b3ecc256fc0dc08d8b9a3784.zip
Stop powerpc copysignl raising "invalid" for sNaN argument (bug 20718).
The powerpc (hard-float) implementations of copysignl, both 32-bit and
64-bit, raise spurious "invalid" exceptions when the first argument is
a signaling NaN.  copysign functions should never raise exceptions
even for signaling NaNs.

The problem is the use of an fcmpu instruction to test the sign of the
high part of the long double argument.  This patch fixes the functions
to use fsel instead (as used for fabsl following my fixes for a
similar bug there), or to examine the integer representation for older
32-bit processors without fsel.

Tested for powerpc64 and powerpc32 (configurations with and without
fsel used).

	[BZ #20718]
	* sysdeps/powerpc/powerpc32/fpu/s_copysignl.S (__copysignl): Do
	not use floating-point comparisons to test sign.
	* sysdeps/powerpc/powerpc64/fpu/s_copysignl.S (__copysignl):
	Likewise.
Diffstat (limited to 'ChangeLog')
-rw-r--r--ChangeLog6
1 files changed, 6 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 9b226786af..49436bcf4b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2016-10-19  Joseph Myers  <joseph@codesourcery.com>
 
+	[BZ #20718]
+	* sysdeps/powerpc/powerpc32/fpu/s_copysignl.S (__copysignl): Do
+	not use floating-point comparisons to test sign.
+	* sysdeps/powerpc/powerpc64/fpu/s_copysignl.S (__copysignl):
+	Likewise.
+
 	* math/bits/mathcalls.h [__GLIBC_USE (IEC_60559_BFP_EXT)]
 	(getpayload): New declaration.
 	* math/Versions (getpayload): New libm symbol at version