glibc/sysdeps/ieee754
Joseph Myers 0e069029a8 Fix dbl-64 lrint for 64-bit long (bug 19095).
The dbl-64 implementation of lrint produces incorrect results for some
arguments with 64-bit long because a 32-bit (unsigned) low part of the
mantissa is shifted left, losing high bits in the process.  This patch
fixes this by casting to long int before shifting, as in lround (as
this case only applies for 64-bit long, there are no issues with
sign-extension).

Tested for mips64 (n64).

	[BZ #19095]
	* sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Cast low part of
	mantissa to long int before shifting left.
2015-10-09 00:32:14 +00:00
..
bits
dbl-64 Fix dbl-64 lrint for 64-bit long (bug 19095). 2015-10-09 00:32:14 +00:00
flt-32 Work around powerpc32 integer 0 converting to -0 (bug 887, bug 19049, bug 19050). 2015-10-05 17:46:50 +00:00
ldbl-64-128 Make scalbn set errno (bug 6803). 2015-09-16 21:11:00 +00:00
ldbl-96 Fix lrint, llrint missing exceptions close to overflow threshold (bug 19094). 2015-10-08 22:17:45 +00:00
ldbl-128 Fix lrint, llrint missing exceptions close to overflow threshold (bug 19094). 2015-10-08 22:17:45 +00:00
ldbl-128ibm Fix ldbl-128ibm expl overflow in non-default rounding modes (bug 19078). 2015-10-06 17:37:49 +00:00
ldbl-opt Fix nexttoward overflow in non-default rounding modes (bug 19059). 2015-10-02 17:11:13 +00:00
ieee754.h
k_standard.c
k_standardf.c
k_standardl.c
Makefile
s_lib_version.c
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