[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

r3523 - in glibc-package/branches/eglibc-2.10/debian: . patches patches/powerpc



Author: aurel32
Date: 2009-05-23 09:00:22 +0000 (Sat, 23 May 2009)
New Revision: 3523

Added:
   glibc-package/branches/eglibc-2.10/debian/patches/powerpc/cvs-long-double-errno.diff
Modified:
   glibc-package/branches/eglibc-2.10/debian/changelog
   glibc-package/branches/eglibc-2.10/debian/patches/series
Log:
  * Add debian/patches/powerpc/cvs-long-double-errno.diff to fix errno for
    IBM long double.



Modified: glibc-package/branches/eglibc-2.10/debian/changelog
===================================================================
--- glibc-package/branches/eglibc-2.10/debian/changelog	2009-05-22 06:20:15 UTC (rev 3522)
+++ glibc-package/branches/eglibc-2.10/debian/changelog	2009-05-23 09:00:22 UTC (rev 3523)
@@ -76,6 +76,10 @@
     crossing page boundaries on ia64.
   * Add debian/patches/any/submitted-accept4.diff to fix nscd on non-amd64
     architectures.
+  * Add debian/patches/any/local-linuxthreads-unwind.diff to fix exception
+    handling with linuxthreads.
+  * Add debian/patches/powerpc/cvs-long-double-errno.diff to fix errno for
+    IBM long double.
 
  -- Aurelien Jarno <aurel32@debian.org>  Sun, 10 May 2009 15:03:39 +0200
 

Added: glibc-package/branches/eglibc-2.10/debian/patches/powerpc/cvs-long-double-errno.diff
===================================================================
--- glibc-package/branches/eglibc-2.10/debian/patches/powerpc/cvs-long-double-errno.diff	                        (rev 0)
+++ glibc-package/branches/eglibc-2.10/debian/patches/powerpc/cvs-long-double-errno.diff	2009-05-23 09:00:22 UTC (rev 3523)
@@ -0,0 +1,105 @@
+2009-05-22  Andreas Schwab  <schwab@linux-m68k.org>
+ 
+	* sysdeps/ieee754/ldbl-128ibm/s_sinl.c: Set errno for ±Inf.
+	* sysdeps/ieee754/ldbl-128ibm/s_cosl.c: Likewise.
+	* sysdeps/ieee754/ldbl-128ibm/s_tanl.c: Likewise.
+	* sysdeps/ieee754/ldbl-128ibm/s_expm1l.c: Set errno for overflow.
+
+ 	* sysdeps/powerpc/powerpc32/____longjmp_chk.S: New file.
+ 	* sysdeps/powerpc/powerpc64/____longjmp_chk.S: New file.
+ 	* sysdeps/powerpc/powerpc32/__longjmp-common.S: Use CHECK_SP if
+
+--- a/sysdeps/ieee754/ldbl-128ibm/s_cosl.c
++++ b/sysdeps/ieee754/ldbl-128ibm/s_cosl.c
+@@ -44,6 +44,7 @@
+  *	TRIG(x) returns trig(x) nearly rounded
+  */
+ 
++#include <errno.h>
+ #include "math.h"
+ #include "math_private.h"
+ #include <math_ldbl_opt.h>
+@@ -67,9 +68,11 @@
+ 	  return __kernel_cosl(x,z);
+ 
+     /* cos(Inf or NaN) is NaN */
+-	else if (ix>=0x7ff0000000000000LL)
++	else if (ix>=0x7ff0000000000000LL) {
++	    if (ix == 0x7ff0000000000000LL)
++		__set_errno (EDOM);
+ 	    return x-x;
+-
++	}
+     /* argument reduction needed */
+ 	else {
+ 	    n = __ieee754_rem_pio2l(x,y);
+--- a/sysdeps/ieee754/ldbl-128ibm/s_expm1l.c
++++ b/sysdeps/ieee754/ldbl-128ibm/s_expm1l.c
+@@ -51,6 +51,7 @@
+     License along with this library; if not, write to the Free Software
+     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA */
+ 
++#include <errno.h>
+ #include "math.h"
+ #include "math_private.h"
+ #include <math_ldbl_opt.h>
+@@ -120,7 +121,10 @@ __expm1l (long double x)
+ 
+   /* Overflow.  */
+   if (x > maxlog)
+-    return (big * big);
++    {
++      __set_errno (ERANGE);
++      return (big * big);
++    }
+ 
+   /* Minimum value.  */
+   if (x < minarg)
+--- a/sysdeps/ieee754/ldbl-128ibm/s_sinl.c
++++ b/sysdeps/ieee754/ldbl-128ibm/s_sinl.c
+@@ -44,6 +44,7 @@
+  *	TRIG(x) returns trig(x) nearly rounded
+  */
+ 
++#include <errno.h>
+ #include "math.h"
+ #include "math_private.h"
+ #include <math_ldbl_opt.h>
+@@ -67,8 +68,11 @@
+ 	  return __kernel_sinl(x,z,0);
+ 
+     /* sin(Inf or NaN) is NaN */
+-	else if (ix>=0x7ff0000000000000LL) return x-x;
+-
++	else if (ix>=0x7ff0000000000000LL) {
++	    if (ix == 0x7ff0000000000000LL)
++		__set_errno (EDOM);
++	    return x-x;
++	}
+     /* argument reduction needed */
+ 	else {
+ 	    n = __ieee754_rem_pio2l(x,y);
+--- a/sysdeps/ieee754/ldbl-128ibm/s_tanl.c
++++ b/sysdeps/ieee754/ldbl-128ibm/s_tanl.c
+@@ -44,6 +44,7 @@
+  *	TRIG(x) returns trig(x) nearly rounded
+  */
+ 
++#include <errno.h>
+ #include "math.h"
+ #include "math_private.h"
+ #include <math_ldbl_opt.h>
+@@ -66,8 +67,11 @@
+ 	if(ix <= 0x3fe921fb54442d10LL) return __kernel_tanl(x,z,1);
+ 
+     /* tanl(Inf or NaN) is NaN */
+-	else if (ix>=0x7ff0000000000000LL) return x-x;		/* NaN */
+-
++	else if (ix>=0x7ff0000000000000LL) {
++	    if (ix == 0x7ff0000000000000LL)
++		__set_errno (EDOM);
++	    return x-x;		/* NaN */
++	}
+     /* argument reduction needed */
+ 	else {
+ 	    n = __ieee754_rem_pio2l(x,y);

Modified: glibc-package/branches/eglibc-2.10/debian/patches/series
===================================================================
--- glibc-package/branches/eglibc-2.10/debian/patches/series	2009-05-22 06:20:15 UTC (rev 3522)
+++ glibc-package/branches/eglibc-2.10/debian/patches/series	2009-05-23 09:00:22 UTC (rev 3523)
@@ -111,6 +111,8 @@
 mips/local-lazy-eval.diff
 mips/local-r10k.diff
 
+powerpc/cvs-long-double-errno.diff
+
 s390/submitted-nexttowardf.diff
 
 sh4/local-fpscr_values.diff


Reply to: