glibc/sysdeps/ieee754
Joseph Myers ce8fc784e6 Fix sign of remquo zero remainder in round-downward mode (bug 17987).
Various remquo implementations produce a zero remainder with the wrong
sign (a zero remainder should always have the sign of the first
argument, as specified in IEEE 754) in round-downward mode, resulting
from the sign of 0 - 0.  This patch checks for zero results and fixes
their sign accordingly.

Tested for x86_64, x86, mips64 and powerpc.

	[BZ #17987]
	* sysdeps/ieee754/dbl-64/s_remquo.c (__remquo): Ensure sign of
	zero result does not depend on the sign resulting from
	subtraction.
	* sysdeps/ieee754/dbl-64/wordsize-64/s_remquo.c (__remquo):
	Likewise.
	* sysdeps/ieee754/flt-32/s_remquof.c (__remquof): Likewise.
	* sysdeps/ieee754/ldbl-128/s_remquol.c (__remquol): Likewise.
	* sysdeps/ieee754/ldbl-128ibm/s_remquol.c (__remquol): Likewise.
	* sysdeps/ieee754/ldbl-96/s_remquol.c (__remquol): Likewise.
	* math/libm-test.inc (remquo_test_data): Add more tests.
2015-02-17 00:41:50 +00:00
..
bits Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
dbl-64 Fix sign of remquo zero remainder in round-downward mode (bug 17987). 2015-02-17 00:41:50 +00:00
flt-32 Fix sign of remquo zero remainder in round-downward mode (bug 17987). 2015-02-17 00:41:50 +00:00
ldbl-64-128 Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
ldbl-96 Fix sign of remquo zero remainder in round-downward mode (bug 17987). 2015-02-17 00:41:50 +00:00
ldbl-128 Fix sign of remquo zero remainder in round-downward mode (bug 17987). 2015-02-17 00:41:50 +00:00
ldbl-128ibm Fix sign of remquo zero remainder in round-downward mode (bug 17987). 2015-02-17 00:41:50 +00:00
ldbl-opt Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
Makefile Update. 2000-02-26 01:21:37 +00:00
ieee754.h Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
k_standard.c Split __kernel_standard* functions (fixes bug 17724). 2014-12-22 18:45:50 +00:00
k_standardf.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
k_standardl.c Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
s_lib_version.c Remove trailing whitespace. 2013-06-05 20:44:03 +00:00
s_matherr.c Use <> for math.h and math_private.h everywhere. 2012-03-09 16:09:10 -08:00
s_signgam.c Use <> for math.h and math_private.h everywhere. 2012-03-09 16:09:10 -08:00
support.c Fix leading whitespaces. 2013-06-06 20:36:07 +02:00