This is the mail archive of the 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.22-483-g5878dd9

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  5878dd9d53a00fa28800236d79e38e55f85fc98d (commit)
      from  1f4dafa3ea24df63a6550dbdbbe8769caa7a9fc3 (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 -----------------------------------------------------------------;a=commitdiff;h=5878dd9d53a00fa28800236d79e38e55f85fc98d

commit 5878dd9d53a00fa28800236d79e38e55f85fc98d
Author: Joseph Myers <>
Date:   Wed Oct 28 21:57:10 2015 +0000

    Use C11 CMPLX* macros in libm tests. has a macro BUILD_COMPLEX to construct a complex number
    with given real and imaginary parts while allowing properly for signed
    zeroes, infinities and NaNs (which don't work properly with a simple
    real + I * imag, in the absence of compiler support for imaginary
    types), using assignment to __real__ and __imag__ parts of the number.
    C11 defines CMPLX* macros for this purpose, which GCC 4.7 and above
    provide suitable built-in functions for.  This patch redefines
    BUILD_COMPLEX in terms of the standard macros.
    Tested for x86_64 and x86.
    	* math/ (BUILD_COMPLEX): Remove macro.
    	* math/test-double.h (BUILD_COMPLEX): New macro.
    	* math/test-float.h (BUILD_COMPLEX): Likewise.
    	* math/test-ldouble.h (BUILD_COMPLEX): Likewise.

diff --git a/ChangeLog b/ChangeLog
index 1feefaf..52cd9f3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2015-10-28  Joseph Myers  <>
+	* math/ (BUILD_COMPLEX): Remove macro.
+	* math/test-double.h (BUILD_COMPLEX): New macro.
+	* math/test-float.h (BUILD_COMPLEX): Likewise.
+	* math/test-ldouble.h (BUILD_COMPLEX): Likewise.
 	* math/ (min_subnorm_value): Use LDBL_TRUE_MIN,
diff --git a/math/ b/math/
index 631b205..17edcfa 100644
--- a/math/
+++ b/math/
@@ -328,12 +328,6 @@ static FLOAT prev_max_error, prev_real_max_error, prev_imag_max_error;
 static FLOAT max_valid_error;
-#define BUILD_COMPLEX(real, imag) \
-  ({ __complex__ FLOAT __retval;					      \
-     __real__ __retval = (real);					      \
-     __imag__ __retval = (imag);					      \
-     __retval; })
diff --git a/math/test-double.h b/math/test-double.h
index 3f2c008..0038acf 100644
--- a/math/test-double.h
+++ b/math/test-double.h
@@ -22,3 +22,4 @@
 #define PRINTF_XEXPR "a"
 #define PRINTF_NEXPR "f"
 #define TEST_DOUBLE 1
+#define BUILD_COMPLEX(real, imag) (CMPLX ((real), (imag)))
diff --git a/math/test-float.h b/math/test-float.h
index 7b00cb1..8bdba55 100644
--- a/math/test-float.h
+++ b/math/test-float.h
@@ -22,3 +22,4 @@
 #define PRINTF_XEXPR "a"
 #define PRINTF_NEXPR "f"
 #define TEST_FLOAT 1
+#define BUILD_COMPLEX(real, imag) (CMPLXF ((real), (imag)))
diff --git a/math/test-ldouble.h b/math/test-ldouble.h
index e42b2bd..4f0858c 100644
--- a/math/test-ldouble.h
+++ b/math/test-ldouble.h
@@ -22,3 +22,4 @@
 #define PRINTF_XEXPR "La"
 #define PRINTF_NEXPR "Lf"
 #define TEST_LDOUBLE 1
+#define BUILD_COMPLEX(real, imag) (CMPLXL ((real), (imag)))


Summary of changes:
 ChangeLog           |    5 +++++
 math/  |    6 ------
 math/test-double.h  |    1 +
 math/test-float.h   |    1 +
 math/test-ldouble.h |    1 +
 5 files changed, 8 insertions(+), 6 deletions(-)

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]