This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch, master, updated. glibc-2.14-451-g8047914


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  804791474dc1f0904f6d91ef66dbbbc322991e0b (commit)
       via  f6ce9294b0a6c5a847109cc41b7ad0c838b9ccfe (commit)
      from  e0016b11d6186a7003d7204cb100acab9bbcd940 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=804791474dc1f0904f6d91ef66dbbbc322991e0b

commit 804791474dc1f0904f6d91ef66dbbbc322991e0b
Author: Andreas Schwab <schwab@redhat.com>
Date:   Wed Oct 26 11:37:08 2011 +0200

    Fix uses of math_force_eval

diff --git a/ChangeLog b/ChangeLog
index 68f7766..57c4bbe 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2011-10-26  Andreas Schwab  <schwab@redhat.com>
 
+	* sysdeps/ieee754/flt-32/e_j0f.c: Fix use of math_force_eval.
+	* sysdeps/ieee754/dbl-64/s_round.c: Likewise.
+	* sysdeps/ieee754/flt-32/s_roundf.c: Likewise.
+
 	* math/math_private.h (math_force_eval): Allow non-addressable
 	arguments.
 	* sysdeps/i386/fpu/math_private.h (math_force_eval): Likewise.
diff --git a/sysdeps/ieee754/dbl-64/s_round.c b/sysdeps/ieee754/dbl-64/s_round.c
index f8a3816..7446196 100644
--- a/sysdeps/ieee754/dbl-64/s_round.c
+++ b/sysdeps/ieee754/dbl-64/s_round.c
@@ -38,7 +38,7 @@ __round (double x)
     {
       if (j0 < 0)
 	{
-	  math_force_eval (huge + x > 0.0);
+	  math_force_eval (huge + x);
 
 	  i0 &= 0x80000000;
 	  if (j0 == -1)
@@ -51,7 +51,7 @@ __round (double x)
 	  if (((i0 & i) | i1) == 0)
 	    /* X is integral.  */
 	    return x;
-	  math_force_eval (huge + x > 0.0);
+	  math_force_eval (huge + x);
 
 	  /* Raise inexact if x != 0.  */
 	  i0 += 0x00080000 >> j0;
@@ -74,7 +74,7 @@ __round (double x)
 	/* X is integral.  */
 	return x;
 
-      math_force_eval (huge + x > 0.0);
+      math_force_eval (huge + x);
 
       /* Raise inexact if x != 0.  */
       u_int32_t j = i1 + (1 << (51 - j0));
diff --git a/sysdeps/ieee754/flt-32/e_j0f.c b/sysdeps/ieee754/flt-32/e_j0f.c
index 181c2e4..0cc52c9 100644
--- a/sysdeps/ieee754/flt-32/e_j0f.c
+++ b/sysdeps/ieee754/flt-32/e_j0f.c
@@ -66,7 +66,7 @@ __ieee754_j0f(float x)
 		return z;
 	}
 	if(ix<0x39000000) {	/* |x| < 2**-13 */
-	    math_force_eval(huge+x>one);	/* raise inexact if x != 0 */
+	    math_force_eval(huge+x);		/* raise inexact if x != 0 */
 	    if(ix<0x32000000) return one;	/* |x|<2**-27 */
 	    else	      return one - (float)0.25*x*x;
 	}
diff --git a/sysdeps/ieee754/flt-32/s_roundf.c b/sysdeps/ieee754/flt-32/s_roundf.c
index 09b38cd..f4f9dd6 100644
--- a/sysdeps/ieee754/flt-32/s_roundf.c
+++ b/sysdeps/ieee754/flt-32/s_roundf.c
@@ -37,7 +37,7 @@ __roundf (float x)
     {
       if (j0 < 0)
 	{
-	  math_force_eval (huge + x > 0.0F);
+	  math_force_eval (huge + x);
 
 	  i0 &= 0x80000000;
 	  if (j0 == -1)
@@ -49,7 +49,7 @@ __roundf (float x)
 	  if ((i0 & i) == 0)
 	    /* X is integral.  */
 	    return x;
-	  math_force_eval (huge + x > 0.0F);
+	  math_force_eval (huge + x);
 
 	  /* Raise inexact if x != 0.  */
 	  i0 += 0x00400000 >> j0;

http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=f6ce9294b0a6c5a847109cc41b7ad0c838b9ccfe

commit f6ce9294b0a6c5a847109cc41b7ad0c838b9ccfe
Author: Andreas Schwab <schwab@redhat.com>
Date:   Wed Oct 26 11:19:35 2011 +0200

    Make math_force_eval accept non-addressable arguments

diff --git a/ChangeLog b/ChangeLog
index 23dab2e..68f7766 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2011-10-26  Andreas Schwab  <schwab@redhat.com>
+
+	* math/math_private.h (math_force_eval): Allow non-addressable
+	arguments.
+	* sysdeps/i386/fpu/math_private.h (math_force_eval): Likewise.
+
 2011-10-25  Ulrich Drepper  <drepper@gmail.com>
 
 	* sysdeps/ieee754/dbl-64/e_rem_pio2.c: Comment everything out, the
diff --git a/math/math_private.h b/math/math_private.h
index 4cb81ea..04c112f 100644
--- a/math/math_private.h
+++ b/math/math_private.h
@@ -354,8 +354,9 @@ extern void __docos (double __x, double __dx, double __v[]);
 
 #ifndef math_opt_barrier
 #define math_opt_barrier(x) \
-({ __typeof (x) __x = x; __asm ("" : "+m" (__x)); __x; })
-#define math_force_eval(x) __asm __volatile ("" : : "m" (x))
+({ __typeof (x) __x = (x); __asm ("" : "+m" (__x)); __x; })
+#define math_force_eval(x) \
+({ __typeof (x) __x = (x); __asm __volatile ("" : : "m" (__x)); })
 #endif
 
 
diff --git a/sysdeps/i386/fpu/math_private.h b/sysdeps/i386/fpu/math_private.h
index a426788..8a51851 100644
--- a/sysdeps/i386/fpu/math_private.h
+++ b/sysdeps/i386/fpu/math_private.h
@@ -1,16 +1,17 @@
 #ifndef _MATH_PRIVATE_H
 
 #define math_opt_barrier(x) \
-({ __typeof(x) __x;					\
+({ __typeof (x) __x;					\
    __asm ("" : "=t" (__x) : "0" (x));			\
    __x; })
 #define math_force_eval(x) \
 do							\
   {							\
+    __typeof (x) __x = (x);				\
     if (sizeof (x) <= sizeof (double))			\
-      __asm __volatile ("" : : "m" (x));		\
+      __asm __volatile ("" : : "m" (__x));		\
     else						\
-      __asm __volatile ("" : : "f" (x));		\
+      __asm __volatile ("" : : "f" (__x));		\
   }							\
 while (0)
 

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                         |   10 ++++++++++
 math/math_private.h               |    5 +++--
 sysdeps/i386/fpu/math_private.h   |    7 ++++---
 sysdeps/ieee754/dbl-64/s_round.c  |    6 +++---
 sysdeps/ieee754/flt-32/e_j0f.c    |    2 +-
 sysdeps/ieee754/flt-32/s_roundf.c |    4 ++--
 6 files changed, 23 insertions(+), 11 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]