r2916 - in glibc-package/trunk/debian: . patches patches/s390
Author: aurel32
Date: 2008-05-05 20:26:20 +0000 (Mon, 05 May 2008)
New Revision: 2916
Added:
glibc-package/trunk/debian/patches/s390/
glibc-package/trunk/debian/patches/s390/submitted-nexttowardf.diff
Modified:
glibc-package/trunk/debian/changelog
glibc-package/trunk/debian/patches/series
Log:
* patches/s390/submitted-nexttowardf.diff: fix IEEE exceptions raising in
nexttowardf() on s390 with gcc-4.3.
Modified: glibc-package/trunk/debian/changelog
===================================================================
--- glibc-package/trunk/debian/changelog 2008-05-05 20:23:10 UTC (rev 2915)
+++ glibc-package/trunk/debian/changelog 2008-05-05 20:26:20 UTC (rev 2916)
@@ -20,12 +20,14 @@
* sysdeps/arm.mk, control.in/main: use gcc-4.3 on arm.
* sysdeps/depflags.pl: conflicts with tzdata-etch.
* kfreebsd/local-sysdeps.diff: update to revision 2163 (from glibc-bsd).
+ * patches/s390/submitted-nexttowardf.diff: fix IEEE exceptions raising in
+ nexttowardf() on s390 with gcc-4.3.
[ Pierre Habouzit ]
* Add any/cvs-strerror_r.diff to make strerror_r actually thread safe.
Closes: #456531.
- -- Aurelien Jarno <aurel32@debian.org> Sat, 12 Apr 2008 22:52:44 +0200
+ -- Aurelien Jarno <aurel32@debian.org> Mon, 05 May 2008 22:24:48 +0200
glibc (2.7-10) unstable; urgency=low
Added: glibc-package/trunk/debian/patches/s390/submitted-nexttowardf.diff
===================================================================
--- glibc-package/trunk/debian/patches/s390/submitted-nexttowardf.diff (rev 0)
+++ glibc-package/trunk/debian/patches/s390/submitted-nexttowardf.diff 2008-05-05 20:26:20 UTC (rev 2916)
@@ -0,0 +1,58 @@
+2008-05-05 Aurelien Jarno <aurelien@aurel32.net>
+
+ * sysdeps/ieee754/ldbl-128/s_nexttowardf.c: Include float.h.
+ (__nexttowardf): Use math_opt_barrier and
+ math_force_eval macros. If FLT_EVAL_METHOD is not 0, force
+ x to float using asm.
+
+--- a/sysdeps/ieee754/ldbl-128/s_nexttowardf.c
++++ b/sysdeps/ieee754/ldbl-128/s_nexttowardf.c
+@@ -19,7 +19,8 @@ static char rcsid[] = "$NetBSD: $";
+ #endif
+
+ #include "math.h"
+-#include "math_private.h"
++#include <math_private.h>
++#include <float.h>
+
+ #ifdef __STDC__
+ float __nexttowardf(float x, long double y)
+@@ -44,10 +45,12 @@ static char rcsid[] = "$NetBSD: $";
+ return x+y;
+ if((long double) x==y) return y; /* x=y, return y */
+ if(ix==0) { /* x == 0 */
+- float x2;
++ float u;
+ SET_FLOAT_WORD(x,(u_int32_t)((hy>>32)&0x80000000)|1);/* return +-minsub*/
+- x2 = x*x;
+- if(x2==x) return x2; else return x; /* raise underflow flag */
++ u = math_opt_barrier (x);
++ u = u * u;
++ math_force_eval (u); /* raise underflow flag */
++ return x;
+ }
+ if(hx>=0) { /* x > 0 */
+ if(hy<0||(ix>>23)>(iy>>48)-0x3f80
+@@ -67,13 +70,16 @@ static char rcsid[] = "$NetBSD: $";
+ }
+ }
+ hy = hx&0x7f800000;
+- if(hy>=0x7f800000) return x+x; /* overflow */
++ if(hy>=0x7f800000) {
++ x = x+x; /* overflow */
++ if (FLT_EVAL_METHOD != 0)
++ /* Force conversion to float. */
++ asm ("" : "+m"(x));
++ return x;
++ }
+ if(hy<0x00800000) { /* underflow */
+- float x2 = x*x;
+- if(x2!=x) { /* raise underflow flag */
+- SET_FLOAT_WORD(x2,hx);
+- return x2;
+- }
++ float u = x*x;
++ math_force_eval (u); /* raise underflow flag */
+ }
+ SET_FLOAT_WORD(x,hx);
+ return x;
Modified: glibc-package/trunk/debian/patches/series
===================================================================
--- glibc-package/trunk/debian/patches/series 2008-05-05 20:23:10 UTC (rev 2915)
+++ glibc-package/trunk/debian/patches/series 2008-05-05 20:26:20 UTC (rev 2916)
@@ -120,6 +120,8 @@
powerpc/local-sysconf.diff
+s390/submitted-nexttowardf.diff -p1
+
sh4/local-fpscr_values.diff -p0
sh4/cvs-nptl-private-futexes.diff -p0
Reply to: