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

[commits] r1161 - in /fsf/trunk/libc: ./ io/ nptl/ nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/ nptl/sysdeps/unix/sysv/linux/x8...



Author: eglibc
Date: Thu Jan 11 00:02:00 2007
New Revision: 1161

Log:
Import glibc-mainline for 2007-01-11

Removed:
    fsf/trunk/libc/sysdeps/i386/soft-fp/
    fsf/trunk/libc/sysdeps/x86_64/soft-fp/
Modified:
    fsf/trunk/libc/ChangeLog
    fsf/trunk/libc/io/fts.c
    fsf/trunk/libc/nptl/ChangeLog
    fsf/trunk/libc/nptl/shlib-versions
    fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c
    fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.h

Modified: fsf/trunk/libc/ChangeLog
==============================================================================
--- fsf/trunk/libc/ChangeLog (original)
+++ fsf/trunk/libc/ChangeLog Thu Jan 11 00:02:00 2007
@@ -1,3 +1,14 @@
+2007-01-11  Jakub Jelinek  <jakub@xxxxxxxxxx>
+
+	* sysdeps/i386/soft-fp/sfp-machine.h: Remove.
+	* sysdeps/x86_64/soft-fp/sfp-machine.h: Likewise.
+
+2007-01-10  Ulrich Drepper  <drepper@xxxxxxxxxx>
+
+	* io/fts.c: Make sure fts_cur is always valid after return from
+	fts_read.
+	Patch by Miloslav Trmac <mitr@xxxxxxxxxx>.
+
 2006-10-27  Richard Sandiford  <richard@xxxxxxxxxxxxxxxx>
 
 	* elf/elf.h (R_MIPS_GLOB_DAT): Define.

Modified: fsf/trunk/libc/io/fts.c
==============================================================================
--- fsf/trunk/libc/io/fts.c (original)
+++ fsf/trunk/libc/io/fts.c Thu Jan 11 00:02:00 2007
@@ -376,12 +376,14 @@
 		}
 		p = sp->fts_child;
 		sp->fts_child = NULL;
+		sp->fts_cur = p;
 		goto name;
 	}
 
 	/* Move to the next node on this level. */
 next:	tmp = p;
 	if ((p = p->fts_link) != NULL) {
+		sp->fts_cur = p;
 		free(tmp);
 
 		/*
@@ -394,7 +396,7 @@
 				return (NULL);
 			}
 			fts_load(sp, p);
-			return (sp->fts_cur = p);
+			return p;
 		}
 
 		/*
@@ -420,11 +422,12 @@
 name:		t = sp->fts_path + NAPPEND(p->fts_parent);
 		*t++ = '/';
 		memmove(t, p->fts_name, p->fts_namelen + 1);
-		return (sp->fts_cur = p);
+		return p;
 	}
 
 	/* Move up to the parent node. */
 	p = tmp->fts_parent;
+	sp->fts_cur = p;
 	free(tmp);
 
 	if (p->fts_level == FTS_ROOTPARENTLEVEL) {
@@ -465,7 +468,7 @@
 		return (NULL);
 	}
 	p->fts_info = p->fts_errno ? FTS_ERR : FTS_DP;
-	return (sp->fts_cur = p);
+	return p;
 }
 
 /*

Modified: fsf/trunk/libc/nptl/ChangeLog
==============================================================================
--- fsf/trunk/libc/nptl/ChangeLog (original)
+++ fsf/trunk/libc/nptl/ChangeLog Thu Jan 11 00:02:00 2007
@@ -1,3 +1,17 @@
+2007-01-10  Ulrich Drepper  <drepper@xxxxxxxxxx>
+
+	* sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Cleanups.  Define
+	FUTEX_CMP_REQUEUE and lll_futex_requeue.
+
+2006-12-28  David S. Miller  <davem@xxxxxxxxxxxxx>
+
+	* shlib-versions: Fix sparc64 linux target specification.
+
+2007-01-10  Jakub Jelinek  <jakub@xxxxxxxxxx>
+
+	* sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
+	Adjust include path for pthread_barrier_wait.c move.
+
 2006-12-21  Jakub Jelinek  <jakub@xxxxxxxxxx>
 
 	* sysdeps/unix/sysv/linux/pthread_kill.c (pthread_kill): Make sure
@@ -71,7 +85,7 @@
 	* sysdeps/pthread/pthread_getcpuclockid.c: Move to...
 	* pthread_getcpuclockid.c: ...here.
 
-	* init.c: USE_TLS support is now default.
+	* init.c: USE_TLS support is now always enabled.
 	* tst-tls5.h: Likewise.
 	* sysdeps/alpha/tls.h: Likewise.
 	* sysdeps/i386/tls.h: Likewise.

Modified: fsf/trunk/libc/nptl/shlib-versions
==============================================================================
--- fsf/trunk/libc/nptl/shlib-versions (original)
+++ fsf/trunk/libc/nptl/shlib-versions Thu Jan 11 00:02:00 2007
@@ -1,5 +1,5 @@
 mips.*-.*-linux.*	libpthread=0		GLIBC_2.0 GLIBC_2.2
-sparc64-.*-linux.*	libpthread=0		GLIBC_2.2
+sparc64.*-.*-linux.*	libpthread=0		GLIBC_2.2
 sh.*-.*-linux.*		libpthread=0		GLIBC_2.2
 ia64.*-.*-linux.*	libpthread=0		GLIBC_2.2
 hppa.*-.*-linux.*	libpthread=0		GLIBC_2.2

Modified: fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c
==============================================================================
--- fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c (original)
+++ fsf/trunk/libc/nptl/sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c Thu Jan 11 00:02:00 2007
@@ -1,1 +1,1 @@
-#include "../../../../../../pthread/pthread_barrier_wait.c"
+#include "../../../../../../../pthread_barrier_wait.c"

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 Thu Jan 11 00:02:00 2007
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2003, 2004, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 2002, 2003, 2004, 2006, 2007 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@xxxxxxxxxx>, 2002.
 
@@ -35,6 +35,7 @@
 #define SYS_futex		202
 #define FUTEX_WAIT		0
 #define FUTEX_WAKE		1
+#define FUTEX_CMP_REQUEUE	4
 #define FUTEX_LOCK_PI		6
 #define FUTEX_UNLOCK_PI		7
 #define FUTEX_TRYLOCK_PI	8
@@ -150,7 +151,7 @@
 #define lll_futex_wait(futex, val) \
   ({									      \
     int __status;							      \
-    register __typeof (val) _val asm ("edx") = (val);			      \
+    register __typeof (val) _val __asm ("edx") = (val);			      \
     __asm __volatile ("xorq %%r10, %%r10\n\t"				      \
 		      "syscall"						      \
 		      : "=a" (__status)					      \
@@ -163,22 +164,22 @@
 
 #define lll_futex_timed_wait(futex, val, timeout)			      \
   ({									      \
-    register const struct timespec *__to __asm__ ("r10") = timeout;	      \
+    register const struct timespec *__to __asm ("r10") = timeout;	      \
     int __status;							      \
-    register __typeof (val) _val asm ("edx") = (val);			      \
+    register __typeof (val) _val __asm ("edx") = (val);			      \
     __asm __volatile ("syscall"						      \
 		      : "=a" (__status)					      \
 		      : "0" (SYS_futex), "D" (futex), "S" (FUTEX_WAIT),	      \
 		        "d" (_val), "r" (__to)				      \
 		      : "memory", "cc", "r11", "cx");			      \
-    __status;								      \
+    -__status;								      \
   })
 
 
 #define lll_futex_wake(futex, nr) \
   do {									      \
     int __ignore;							      \
-    register __typeof (nr) _nr asm ("edx") = (nr);			      \
+    register __typeof (nr) _nr __asm ("edx") = (nr);			      \
     __asm __volatile ("syscall"						      \
 		      : "=a" (__ignore)					      \
 		      : "0" (SYS_futex), "D" (futex), "S" (FUTEX_WAKE),	      \
@@ -421,6 +422,21 @@
 				"S" (FUTEX_WAKE), "1" (__NR_futex),	      \
 				"d" (1)					      \
 			      : "cx", "r11", "cc", "memory"); })
+
+
+/* Returns non-zero if error happened, zero if success.  */
+#define lll_futex_requeue(ftx, nr_wake, nr_move, mutex, val) \
+  ({ int __res;								      \
+     register int __nr_move __asm ("r10") = nr_move;			      \
+     register void *__mutex __asm ("r8") = mutex;			      \
+     register int __val __asm ("r9") = val;				      \
+     __asm __volatile ("syscall"					      \
+		       : "=a" (__res)					      \
+		       : "0" (__NR_futex), "D" ((void *) ftx),		      \
+		         "S" (FUTEX_CMP_REQUEUE), "d" (nr_wake),	      \
+		         "r" (__nr_move), "r" (__mutex), "r" (__val)	      \
+		       : "cx", "r11", "cc", "memory");			      \
+     __res < 0; })
 
 
 #define lll_mutex_islocked(futex) \