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

[Commits] r23262 - in /fsf/trunk/libc: ./ benchtests/ mach/ math/ nptl/ nptl/sysdeps/unix/sysv/linux/i386/ nptl/sysdeps/unix/sysv/linu...



Author: eglibc
Date: Tue Jun 11 00:01:57 2013
New Revision: 23262

Log:
Import glibc-mainline for 2013-06-11

Added:
    fsf/trunk/libc/ports/sysdeps/arm/math-tests.h
Modified:
    fsf/trunk/libc/ChangeLog
    fsf/trunk/libc/benchtests/Makefile
    fsf/trunk/libc/mach/err_boot.sub
    fsf/trunk/libc/mach/err_ipc.sub
    fsf/trunk/libc/mach/err_mach.sub
    fsf/trunk/libc/math/libm-test.inc
    fsf/trunk/libc/nptl/ChangeLog
    fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/i386/lowlevellock.h
    fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
    fsf/trunk/libc/ports/ChangeLog.arm
    fsf/trunk/libc/sysdeps/generic/math-tests.h

Modified: fsf/trunk/libc/ChangeLog
==============================================================================
--- fsf/trunk/libc/ChangeLog (original)
+++ fsf/trunk/libc/ChangeLog Tue Jun 11 00:01:57 2013
@@ -1,3 +1,24 @@
+2013-06-10  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
+
+	* mach/err_boot.sub: Remove trailing whitespace.
+	* mach/err_ipc.sub: Likewise.
+	* mach/err_mach.sub: Likewise.
+
+	* sysdeps/generic/math-tests.h (ROUNDING_TESTS_float): New macro.
+	(ROUNDING_TESTS_double): Likewise.
+	(ROUNDING_TESTS_long_double): Likewise.
+	(ROUNDING_TESTS): Likewise.
+	* math/libm-test.inc: Include <math-tests.h>.
+	(IF_ROUND_INIT_FE_DOWNWARD): Use ROUNDING_TESTS.
+	(IF_ROUND_INIT_FE_TONEAREST): Likewise.
+	(IF_ROUND_INIT_FE_TOWARDZERO): Likewise.
+	(IF_ROUND_INIT_FE_UPWARD): Likewise.
+
+2013-06-10  Siddhesh Poyarekar  <siddhesh@xxxxxxxxxx>
+
+	* benchtests/Makefile (CPPFLAGS-nonlib): Append values instead
+	of assigning.
+
 2013-06-08  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
 
 	* sysdeps/gnu/errlist.awk: Do not generate space at end of

Modified: fsf/trunk/libc/benchtests/Makefile
==============================================================================
--- fsf/trunk/libc/benchtests/Makefile (original)
+++ fsf/trunk/libc/benchtests/Makefile Tue Jun 11 00:01:57 2013
@@ -102,7 +102,7 @@
 BENCH_DURATION := 10
 endif
 
-CPPFLAGS-nonlib = -DDURATION=$(BENCH_DURATION)
+CPPFLAGS-nonlib += -DDURATION=$(BENCH_DURATION)
 
 # Use clock_gettime to measure performance of functions.  The default is to use
 # HP_TIMING if it is available.

Modified: fsf/trunk/libc/mach/err_boot.sub
==============================================================================
--- fsf/trunk/libc/mach/err_boot.sub (original)
+++ fsf/trunk/libc/mach/err_boot.sub Tue Jun 11 00:01:57 2013
@@ -1,26 +1,26 @@
-/* 
+/*
  * Mach Operating System
  * Copyright (c) 1992 Carnegie Mellon University
  * All Rights Reserved.
- * 
+ *
  * Permission to use, copy, modify and distribute this software and its
  * documentation is hereby granted, provided that both the copyright
  * notice and this permission notice appear in all copies of the
  * software, derivative works or modified versions, and any portions
  * thereof, and that both notices appear in supporting documentation.
- * 
+ *
  * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
  * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
  * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
- * 
+ *
  * Carnegie Mellon requests users of this software to return to
- * 
+ *
  *  Software Distribution Coordinator  or  Software.Distribution@xxxxxxxxxx
  *  School of Computer Science
  *  Carnegie Mellon University
  *  Pittsburgh PA 15213-3890
- * 
- * any improvements or extensions that they make and grant Carnegie Mellon 
+ *
+ * any improvements or extensions that they make and grant Carnegie Mellon
  * the rights to redistribute these changes.
  */
 /*
@@ -32,7 +32,7 @@
  * Revision 2.2  92/04/01  19:37:59  rpd
  * 	Created.
  * 	[92/03/09            rpd]
- * 
+ *
  */
 /*
  *	File:	err_bootstrap.sub

Modified: fsf/trunk/libc/mach/err_ipc.sub
==============================================================================
--- fsf/trunk/libc/mach/err_ipc.sub (original)
+++ fsf/trunk/libc/mach/err_ipc.sub Tue Jun 11 00:01:57 2013
@@ -1,25 +1,25 @@
-/* 
+/*
  * Mach Operating System
  * Copyright (c) 1991,1990,1989,1988,1987 Carnegie Mellon University
  * All Rights Reserved.
- * 
+ *
  * Permission to use, copy, modify and distribute this software and its
  * documentation is hereby granted, provided that both the copyright
  * notice and this permission notice appear in all copies of the
  * software, derivative works or modified versions, and any portions
  * thereof, and that both notices appear in supporting documentation.
- * 
- * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS 
+ *
+ * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS
  * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
  * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
- * 
+ *
  * Carnegie Mellon requests users of this software to return to
- * 
+ *
  *  Software Distribution Coordinator  or  Software.Distribution@xxxxxxxxxx
  *  School of Computer Science
  *  Carnegie Mellon University
  *  Pittsburgh PA 15213-3890
- * 
+ *
  * any improvements or extensions that they make and grant Carnegie the
  * rights to redistribute these changes.
  */
@@ -31,11 +31,11 @@
  *
  * Revision 2.2  92/01/16  00:08:40  rpd
  * 	Moved from user collection to mk collection.
- * 
+ *
  * Revision 2.2  91/03/27  16:05:16  mrt
  * 	First checkin
- * 
- * 
+ *
+ *
  */
 /*
  *	File:	err_ipc.sub
@@ -52,7 +52,7 @@
 	"(ipc/send) timed out",			/* -103 */
 	"(ipc/send) unused error",		/* -104 */
 	"(ipc/send) will notify",		/* -105 */
-	"(ipc/send) notify in progress",	/* -106 */	
+	"(ipc/send) notify in progress",	/* -106 */
 	"(ipc/send) kernel refused message",	/* -107 */
 	"(ipc/send) send interrupted",		/* -108 */
 	"(ipc/send) send message too large",	/* -109 */

Modified: fsf/trunk/libc/mach/err_mach.sub
==============================================================================
--- fsf/trunk/libc/mach/err_mach.sub (original)
+++ fsf/trunk/libc/mach/err_mach.sub Tue Jun 11 00:01:57 2013
@@ -1,25 +1,25 @@
-/* 
+/*
  * Mach Operating System
  * Copyright (c) 1991,1990,1989 Carnegie Mellon University
  * All Rights Reserved.
- * 
+ *
  * Permission to use, copy, modify and distribute this software and its
  * documentation is hereby granted, provided that both the copyright
  * notice and this permission notice appear in all copies of the
  * software, derivative works or modified versions, and any portions
  * thereof, and that both notices appear in supporting documentation.
- * 
- * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS 
+ *
+ * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS
  * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
  * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
- * 
+ *
  * Carnegie Mellon requests users of this software to return to
- * 
+ *
  *  Software Distribution Coordinator  or  Software.Distribution@xxxxxxxxxx
  *  School of Computer Science
  *  Carnegie Mellon University
  *  Pittsburgh PA 15213-3890
- * 
+ *
  * any improvements or extensions that they make and grant Carnegie the
  * rights to redistribute these changes.
  */
@@ -32,21 +32,21 @@
  * Revision 2.3  92/04/01  19:38:05  rpd
  * 	Added MIG_DESTROY_REQUEST.
  * 	[92/03/09            rpd]
- * 
+ *
  * Revision 2.2  92/01/16  00:09:05  rpd
  * 	Moved from user collection to mk collection.
- * 
+ *
  * Revision 2.3  91/08/29  15:51:30  rpd
  * 	Added MIG_SERVER_DIED.
  * 	[91/08/21            rpd]
- * 
+ *
  * Revision 2.2  91/03/27  16:05:37  mrt
  * 	First checkin
- * 
+ *
  * Revision 2.2  91/03/18  17:39:03  rpd
  * 	Created.
  * 	[91/03/18            rpd]
- * 
+ *
  */
 /*
  *	File:	err_mach_ipc.sub

Modified: fsf/trunk/libc/math/libm-test.inc
==============================================================================
--- fsf/trunk/libc/math/libm-test.inc (original)
+++ fsf/trunk/libc/math/libm-test.inc Tue Jun 11 00:01:57 2013
@@ -125,6 +125,7 @@
 #include <string.h>
 #include <argp.h>
 #include <tininess.h>
+#include <math-tests.h>
 
 /* Structure for ulp data for a test, a function, or the real or
    imaginary part of a function.  */
@@ -1085,16 +1086,20 @@
 #define IF_ROUND_INIT_	/* Empty.  */
 #define IF_ROUND_INIT_FE_DOWNWARD		\
   int save_round_mode = fegetround ();		\
-  if (fesetround (FE_DOWNWARD) == 0)
+  if (ROUNDING_TESTS (FLOAT, FE_DOWNWARD)	\
+      && fesetround (FE_DOWNWARD) == 0)
 #define IF_ROUND_INIT_FE_TONEAREST		\
   int save_round_mode = fegetround ();		\
-  if (fesetround (FE_TONEAREST) == 0)
+  if (ROUNDING_TESTS (FLOAT, FE_TONEAREST)	\
+      && fesetround (FE_TONEAREST) == 0)
 #define IF_ROUND_INIT_FE_TOWARDZERO		\
   int save_round_mode = fegetround ();		\
-  if (fesetround (FE_TOWARDZERO) == 0)
+  if (ROUNDING_TESTS (FLOAT, FE_TOWARDZERO)	\
+      && fesetround (FE_TOWARDZERO) == 0)
 #define IF_ROUND_INIT_FE_UPWARD			\
   int save_round_mode = fegetround ();		\
-  if (fesetround (FE_UPWARD) == 0)
+  if (ROUNDING_TESTS (FLOAT, FE_UPWARD)		\
+      && fesetround (FE_UPWARD) == 0)
 #define ROUND_RESTORE_	/* Empty.  */
 #define ROUND_RESTORE_FE_DOWNWARD		\
   fesetround (save_round_mode)

Modified: fsf/trunk/libc/nptl/ChangeLog
==============================================================================
--- fsf/trunk/libc/nptl/ChangeLog (original)
+++ fsf/trunk/libc/nptl/ChangeLog Tue Jun 11 00:01:57 2013
@@ -1,3 +1,10 @@
+2013-06-10  Carlos O'Donell  <carlos@xxxxxxxxxx>
+
+	* sysdeps/unix/sysv/linux/i386/lowlevellock.h
+	(lll_futex_wake): Return syscall error.
+	* sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
+	(lll_futex_wake): Return syscall error.
+
 2013-08-06   OndÃÂej BÃÂlka  <neleai@xxxxxxxxx>
 
 	* sysdeps/pthread/allocalim.h: (__libc_use_alloca): Fix warning.

Modified: fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/i386/lowlevellock.h
==============================================================================
--- fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/i386/lowlevellock.h (original)
+++ fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/i386/lowlevellock.h Tue Jun 11 00:01:57 2013
@@ -224,20 +224,21 @@
 
 
 #define lll_futex_wake(futex, nr, private) \
-  do {									      \
-    int __ignore;							      \
+  ({									      \
+    int __status;							      \
     register __typeof (nr) _nr asm ("edx") = (nr);			      \
     LIBC_PROBE (lll_futex_wake, 3, futex, nr, private);                       \
     __asm __volatile (LLL_EBX_LOAD					      \
 		      LLL_ENTER_KERNEL					      \
 		      LLL_EBX_LOAD					      \
-		      : "=a" (__ignore)					      \
+		      : "=a" (__status)					      \
 		      : "0" (SYS_futex), LLL_EBX_REG (futex),		      \
 			"c" (__lll_private_flag (FUTEX_WAKE, private)),	      \
 			"d" (_nr),					      \
 			"i" (0) /* phony, to align next arg's number */,      \
 			"i" (offsetof (tcbhead_t, sysinfo)));		      \
-  } while (0)
+    __status;								      \
+  })
 
 
 /* NB: in the lll_trylock macro we simply return the value in %eax

Modified: fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
==============================================================================
--- fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (original)
+++ fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.h Tue Jun 11 00:01:57 2013
@@ -225,17 +225,18 @@
 
 
 #define lll_futex_wake(futex, nr, private) \
-  do {									      \
-    int __ignore;							      \
+  ({									      \
+    int __status;							      \
     register __typeof (nr) _nr __asm ("edx") = (nr);			      \
     LIBC_PROBE (lll_futex_wake, 3, futex, nr, private);                       \
     __asm __volatile ("syscall"						      \
-		      : "=a" (__ignore)					      \
+		      : "=a" (__status)					      \
 		      : "0" (SYS_futex), "D" (futex),			      \
 			"S" (__lll_private_flag (FUTEX_WAKE, private)),	      \
 			"d" (_nr)					      \
 		      : "memory", "cc", "r10", "r11", "cx");		      \
-  } while (0)
+    __status;								      \
+  })
 
 
 /* NB: in the lll_trylock macro we simply return the value in %eax

Modified: fsf/trunk/libc/ports/ChangeLog.arm
==============================================================================
--- fsf/trunk/libc/ports/ChangeLog.arm (original)
+++ fsf/trunk/libc/ports/ChangeLog.arm Tue Jun 11 00:01:57 2013
@@ -1,3 +1,7 @@
+2013-06-10  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
+
+	* sysdeps/arm/math-tests.h: New file.
+
 2013-06-05  Richard Henderson  <rth@xxxxxxxxxx>
 
 	[BZ #15583]

Added: fsf/trunk/libc/ports/sysdeps/arm/math-tests.h
==============================================================================
--- fsf/trunk/libc/ports/sysdeps/arm/math-tests.h (added)
+++ fsf/trunk/libc/ports/sysdeps/arm/math-tests.h Tue Jun 11 00:01:57 2013
@@ -1,0 +1,28 @@
+/* Configuration for math tests.  ARM version.
+   Copyright (C) 2013 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, see
+   <http://www.gnu.org/licenses/>.  */
+
+/* On systems with VFP support, but where glibc is built for
+   soft-float, the libgcc functions used in libc and libm do not
+   support rounding modes, although fesetround succeeds.  */
+#ifdef __SOFTFP__
+# define ROUNDING_TESTS_float(MODE)	((MODE) == FE_TONEAREST)
+# define ROUNDING_TESTS_double(MODE)	((MODE) == FE_TONEAREST)
+# define ROUNDING_TESTS_long_double(MODE)	((MODE) == FE_TONEAREST)
+#endif
+
+#include_next <math-tests.h>

Modified: fsf/trunk/libc/sysdeps/generic/math-tests.h
==============================================================================
--- fsf/trunk/libc/sysdeps/generic/math-tests.h (original)
+++ fsf/trunk/libc/sysdeps/generic/math-tests.h Tue Jun 11 00:01:57 2013
@@ -40,3 +40,21 @@
 #ifndef SNAN_TESTS_TYPE_CAST
 # define SNAN_TESTS_TYPE_CAST	1
 #endif
+
+/* Indicate whether to run tests involving a given rounding mode for a
+   given floating-point type, given that fesetround succeeds for that
+   mode.  All are run if fesetround succeeds unless overridden.  */
+#ifndef ROUNDING_TESTS_float
+# define ROUNDING_TESTS_float(MODE)	1
+#endif
+#ifndef ROUNDING_TESTS_double
+# define ROUNDING_TESTS_double(MODE)	1
+#endif
+#ifndef ROUNDING_TESTS_long_double
+# define ROUNDING_TESTS_long_double(MODE)	1
+#endif
+
+#define ROUNDING_TESTS(TYPE, MODE)					\
+  (sizeof (TYPE) == sizeof (float) ? ROUNDING_TESTS_float (MODE)	\
+   : sizeof (TYPE) == sizeof (double) ? ROUNDING_TESTS_double (MODE)	\
+   : ROUNDING_TESTS_long_double (MODE))

_______________________________________________
Commits mailing list
Commits@xxxxxxxxxx
http://eglibc.org/cgi-bin/mailman/listinfo/commits