diff mbox

Misc libquadmath backports from upstram glibc (PR libquadmath/65757)

Message ID 20170720083107.GE2123@tucnak
State New
Headers show

Commit Message

Jakub Jelinek July 20, 2017, 8:31 a.m. UTC
On Thu, Jul 13, 2017 at 10:47:06PM +0200, Jakub Jelinek wrote:
> This patch is a manual backport of the 2012-2017 sysdeps/ieee754/ldbl-128/
> glibc changes into libquadmath.  As mentioned in the PR, which has
> detailed git diff commands, I've left *jnl.c, *lgamma* and x2y2m1l.c
> changes so far, those were too large, and the long double -> _Float128
> and 123.456L -> L(123.456) changes.
> 
> Bootstrapped/regtested on x86_64-linux and i686-linux, no further testing
> done though.  I'll commit this next week unless I hear objections.
> Of course, further testing e.g. using glibc testsuite would be greatly
> appreciated.

The patch is now in since yesterday, please let me know if you find any
issues.  For 7.x, I've just cherry-picked the single small change instead:

2017-07-20  Jakub Jelinek  <jakub@redhat.com>

	PR libquadmath/65757
	* math/roundq.c: Cherry-pick upstream glibc 2015-04-28 change.



	Jakub
diff mbox

Patch

--- libquadmath/math/roundq.c.jj	2017-04-20 12:16:38.000000000 +0200
+++ libquadmath/math/roundq.c	2017-07-20 10:26:15.290890331 +0200
@@ -1,5 +1,5 @@ 
 /* Round __float128 to integer away from zero.
-   Copyright (C) 1997, 1999 Free Software Foundation, Inc.
+   Copyright (C) 1997-2017 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997 and
 		  Jakub Jelinek <jj@ultra.linux.cz>, 1999.
@@ -32,7 +32,7 @@  roundq (__float128 x)
 
   GET_FLT128_WORDS64 (i0, i1, x);
   j0 = ((i0 >> 48) & 0x7fff) - 0x3fff;
-  if (j0 < 31)
+  if (j0 < 48)
     {
       if (j0 < 0)
 	{