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

[commits] r8072 - in /fsf/trunk/libc: ./ nptl/ nptl/sysdeps/unix/sysv/linux/sparc/ sysdeps/powerpc/fpu/ sysdeps/unix/sysv/linux/powerp...



Author: eglibc
Date: Tue Mar 10 00:04:40 2009
New Revision: 8072

Log:
Import glibc-mainline for 2009-03-10

Modified:
    fsf/trunk/libc/ChangeLog
    fsf/trunk/libc/nptl/ChangeLog
    fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h
    fsf/trunk/libc/sysdeps/powerpc/fpu/fenv_libc.h
    fsf/trunk/libc/sysdeps/powerpc/fpu/tst-setcontext-fpscr.c
    fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
    fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S
    fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S
    fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S

Modified: fsf/trunk/libc/ChangeLog
==============================================================================
--- fsf/trunk/libc/ChangeLog (original)
+++ fsf/trunk/libc/ChangeLog Tue Mar 10 00:04:40 2009
@@ -1,3 +1,17 @@
+2009-02-18  Jakub Jelinek  <jakub@xxxxxxxxxx>
+
+	* sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S: Use
+	.machine push; .machine "power6" and .machine pop around mtfsf
+	insns outside of _ARCH_PWR6 define.
+	* sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S: Likewise.
+	* sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S:
+	Likewise.
+	* sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S:
+	Likewise.
+	* sysdeps/powerpc/fpu/tst-setcontext-fpscr.c (_SET_DI_FPSCR): Likewise.
+	* sysdeps/powerpc/fpu/fenv_libc.h (fesetenv_register,
+	relax_fenv_state): Likewise.
+
 2009-03-08  Ulrich Drepper  <drepper@xxxxxxxxxx>
 
 	* stdlib/Makefile (routines): Add quick_exit, at_quick_exit, and

Modified: fsf/trunk/libc/nptl/ChangeLog
==============================================================================
--- fsf/trunk/libc/nptl/ChangeLog (original)
+++ fsf/trunk/libc/nptl/ChangeLog Tue Mar 10 00:04:40 2009
@@ -1,3 +1,9 @@
+2009-03-09  Jakub Jelinek  <jakub@xxxxxxxxxx>
+
+	* sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Define
+	FUTEX_WAIT_BITSET, FUTEX_WAKE_BITSET, FUTEX_CLOCK_REALTIME and
+	FUTEX_BITSET_MATCH_ANY.
+
 2009-02-27  Roland McGrath  <roland@xxxxxxxxxx>
 
 	* init.c (__nptl_initial_report_events): Mark __attribute_used__.

Modified: fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h
==============================================================================
--- fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h (original)
+++ fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/sparc/lowlevellock.h Tue Mar 10 00:04:40 2009
@@ -1,4 +1,5 @@
-/* Copyright (C) 2003, 2004, 2006, 2007, 2008 Free Software Foundation, Inc.
+/* Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009
+   Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Jakub Jelinek <jakub@xxxxxxxxxx>, 2003.
 
@@ -36,7 +37,12 @@
 #define FUTEX_LOCK_PI		6
 #define FUTEX_UNLOCK_PI		7
 #define FUTEX_TRYLOCK_PI	8
+#define FUTEX_WAIT_BITSET	9
+#define FUTEX_WAKE_BITSET	10
 #define FUTEX_PRIVATE_FLAG	128
+#define FUTEX_CLOCK_REALTIME	256
+
+#define FUTEX_BITSET_MATCH_ANY	0xffffffff
 
 
 /* Values for 'private' parameter of locking macros.  Yes, the

Modified: fsf/trunk/libc/sysdeps/powerpc/fpu/fenv_libc.h
==============================================================================
--- fsf/trunk/libc/sysdeps/powerpc/fpu/fenv_libc.h (original)
+++ fsf/trunk/libc/sysdeps/powerpc/fpu/fenv_libc.h Tue Mar 10 00:04:40 2009
@@ -1,5 +1,5 @@
 /* Internal libc stuff for floating point environment routines.
-   Copyright (C) 1997, 2006, 2008 Free Software Foundation, Inc.
+   Copyright (C) 1997, 2006, 2008, 2009 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
@@ -39,7 +39,10 @@
 	do { \
 	  double d = (env); \
 	  if(GLRO(dl_hwcap) & PPC_FEATURE_HAS_DFP) \
-	    asm volatile ("mtfsf 0xff,%0,1,0" : : "f" (d)); \
+	    asm volatile (".machine push; " \
+			  ".machine \"power6\"; " \
+			  "mtfsf 0xff,%0,1,0; " \
+			  ".machine pop" : : "f" (d)); \
 	  else \
 	    asm volatile ("mtfsf 0xff,%0" : : "f" (d)); \
 	} while(0)
@@ -52,8 +55,9 @@
    functions.  */
 #define relax_fenv_state() \
 	do { \
-	   if(GLRO(dl_hwcap) & PPC_FEATURE_HAS_DFP) \
-	       asm ("mtfsfi 7,0,1"); \
+	   if (GLRO(dl_hwcap) & PPC_FEATURE_HAS_DFP) \
+	     asm (".machine push; .machine \"power6\"; " \
+		  "mtfsfi 7,0,1; .machine pop"); \
 	   asm ("mtfsfi 7,0"); \
 	} while(0)
 

Modified: fsf/trunk/libc/sysdeps/powerpc/fpu/tst-setcontext-fpscr.c
==============================================================================
--- fsf/trunk/libc/sysdeps/powerpc/fpu/tst-setcontext-fpscr.c (original)
+++ fsf/trunk/libc/sysdeps/powerpc/fpu/tst-setcontext-fpscr.c Tue Mar 10 00:04:40 2009
@@ -111,7 +111,11 @@
     tmp __attribute__ ((__aligned__(8)));				     \
   tmp.fpscr = __fpscr;							     \
   /* Set the entire 64-bit FPSCR.  */					     \
-  __asm__ ("lfd%U0 0,%0; mtfsf 255,0,1,0" : : "m" (tmp.d) : "fr0");	     \
+  __asm__ ("lfd%U0 0,%0; "						     \
+	   ".machine push; "						     \
+	   ".machine \"power6\"; "					     \
+	   "mtfsf 255,0,1,0; "						     \
+	   ".machine pop" : : "m" (tmp.d) : "fr0");			     \
   tmp.d = 0;								     \
   __asm__("lfd%U0 0,%0" : : "m" (tmp.d) : "fr0");			     \
 }

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext-common.S Tue Mar 10 00:04:40 2009
@@ -204,6 +204,8 @@
 	/* Use the extended four-operand version of the mtfsf insn.  */
 	mtfsf	0xff,fp31,1,0
 # else
+	.machine push
+	.machine "power6"
 	/* Availability of DFP indicates a 64-bit FPSCR.  */
 	andi.	r6,r7,PPC_FEATURE_HAS_DFP
 	beq	7f
@@ -212,7 +214,7 @@
 	b	8f
 	/* Continue to operate on the FPSCR as if it were 32-bits.  */
 7:	mtfsf	0xff,fp31
-8:
+8:	.machine pop
 # endif /* _ARCH_PWR6 */
 	lfd	fp1,_UC_FREGS+(1*8)(r31)
 	lfd	fp2,_UC_FREGS+(2*8)(r31)

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext-common.S Tue Mar 10 00:04:40 2009
@@ -430,6 +430,8 @@
 	/* Use the extended four-operand version of the mtfsf insn.  */
 	mtfsf	0xff,fp31,1,0
 # else
+	.machine push
+	.machine "power6"
 	/* Availability of DFP indicates a 64-bit FPSCR.  */
 	andi.	r6,r7,PPC_FEATURE_HAS_DFP
 	beq	7f
@@ -438,7 +440,7 @@
 	b	8f
 	/* Continue to operate on the FPSCR as if it were 32-bits.  */
 7:	mtfsf	0xff,fp31
-8:
+8:	.machine pop
 #endif /* _ARCH_PWR6 */
 	lfd	fp1,_UC_FREGS+(1*8)(r31)
 	lfd	fp2,_UC_FREGS+(2*8)(r31)

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S Tue Mar 10 00:04:40 2009
@@ -1,5 +1,6 @@
 /* Switch to context.
-   Copyright (C) 2002, 2004, 2005, 2006, 2008 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2004, 2005, 2006, 2008, 2009
+   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
@@ -86,6 +87,8 @@
   /* Use the extended four-operand version of the mtfsf insn.  */
   mtfsf  0xff,fp0,1,0
 # else
+  .machine push
+  .machine "power6"
   /* Availability of DFP indicates a 64-bit FPSCR.  */
   andi.  r6,r5,PPC_FEATURE_HAS_DFP
   beq    5f
@@ -96,6 +99,7 @@
 5:
   mtfsf  0xff,fp0
 6:
+  .machine pop
 # endif /* _ARCH_PWR6 */
   lfd  fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31)
   lfd  fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r31)
@@ -374,6 +378,8 @@
   /* Use the extended four-operand version of the mtfsf insn.  */
   mtfsf  0xff,fp0,1,0
 # else
+  .machine push
+  .machine "power6"
   /* Availability of DFP indicates a 64-bit FPSCR.  */
   andi.  r6,r5,PPC_FEATURE_HAS_DFP
   beq    7f
@@ -384,6 +390,7 @@
 7:
   mtfsf  0xff,fp0
 8:
+  .machine pop
 # endif /* _ARCH_PWR6 */
   lfd  fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31)
   lfd  fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r31)

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S Tue Mar 10 00:04:40 2009
@@ -1,5 +1,6 @@
 /* Save current context and install the given one.
-   Copyright (C) 2002, 2004, 2005, 2006, 2008 Free Software Foundation, Inc.
+   Copyright (C) 2002, 2004, 2005, 2006, 2008, 2009
+   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
@@ -180,6 +181,8 @@
   /* Use the extended four-operand version of the mtfsf insn.  */
   mtfsf  0xff,fp0,1,0
 # else
+  .machine push
+  .machine "power6"
   /* Availability of DFP indicates a 64-bit FPSCR.  */
   andi.  r6,r8,PPC_FEATURE_HAS_DFP
   beq    5f
@@ -190,6 +193,7 @@
 5:
   mtfsf  0xff,fp0
 6:
+  .machine pop
 #endif /* _ARCH_PWR6 */
   lfd  fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31)
   lfd  fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r31)
@@ -672,6 +676,8 @@
   /* Use the extended four-operand version of the mtfsf insn.  */
   mtfsf  0xff,fp0,1,0
 # else
+  .machine push
+  .machine "power6"
   /* Availability of DFP indicates a 64-bit FPSCR.  */
   andi.  r6,r8,PPC_FEATURE_HAS_DFP
   beq    7f
@@ -682,6 +688,7 @@
 7:
   mtfsf  0xff,fp0
 8:
+  .machine pop
 #endif /* _ARCH_PWR6 */
   lfd  fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31)
   lfd  fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r31)