Browse Source

x86_64: fix up the rest of the includes and aliases for nptl

Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Austin Foxley 14 years ago
parent
commit
02a89fe640

+ 11 - 0
libpthread/nptl/sysdeps/pthread/Makefile.in

@@ -43,6 +43,17 @@ SH_PTHREAD_EXCLUDE_LIST = pthread_spin_unlock.c pthread_spin_init.c \
 libpthread_CSRC := $(filter-out $(SH_PTHREAD_EXCLUDE_LIST),$(libpthread_CSRC))
 endif
 
+ifeq ($(TARGET_ARCH),x86_64)
+X64_PTHREAD_EXCLUDE_LIST = pthread_spin_unlock.c pthread_spin_init.c \
+		pthread_barrier_wait.c pthread_cond_broadcast.c	\
+		pthread_cond_signal.c pthread_rwlock_timedrdlock.c	\
+		pthread_rwlock_timedwrlock.c pthread_rwlock_unlock.c pthread_rwlock_wrlock.c \
+		pthread_rwlock_rdlock.c pthread_cond_timedwait.c
+
+libpthread_CSRC := $(filter-out $(X64_PTHREAD_EXCLUDE_LIST),$(libpthread_CSRC))
+endif
+
+
 
 CFLAGS-pt-common = -DNOT_IN_libc=1 $(SSP_ALL_CFLAGS)
 

+ 1 - 1
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/Makefile.arch

@@ -18,7 +18,7 @@ libpthread_SSRC += lowlevellock.S pthread_barrier_wait.S pthread_cond_signal.S p
 		   sem_post.S sem_timedwait.S \
 		   sem_trywait.S sem_wait.S pthread_rwlock_rdlock.S pthread_rwlock_wrlock.S \
 		   pthread_rwlock_timedrdlock.S pthread_rwlock_timedwrlock.S pthread_rwlock_unlock.S \
-		   pthread_cond_timedwait.S pthread_cond_wait.S
+		   pthread_cond_timedwait.S pthread_cond_wait.S pthread_spin_unlock.S
 
 libc_a_SSRC += libc-lowlevellock.S
 

+ 2 - 2
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S

@@ -132,5 +132,5 @@ __pthread_cond_broadcast:
 	syscall
 	jmp	10b
 	.size	__pthread_cond_broadcast, .-__pthread_cond_broadcast
-versioned_symbol (libpthread, __pthread_cond_broadcast, pthread_cond_broadcast,
-		  GLIBC_2_3_2)
+weak_alias(__pthread_cond_broadcast, pthread_cond_broadcast)
+

+ 1 - 2
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S

@@ -98,5 +98,4 @@ __pthread_cond_signal:
 	callq	__lll_mutex_unlock_wake
 	jmp	6b
 	.size	__pthread_cond_signal, .-__pthread_cond_signal
-versioned_symbol (libpthread, __pthread_cond_signal, pthread_cond_signal,
-		  GLIBC_2_3_2)
+weak_alias(__pthread_cond_signal, pthread_cond_signal)

+ 2 - 2
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S

@@ -20,6 +20,7 @@
 #include <sysdep.h>
 #include <lowlevelcond.h>
 #include <pthread-errnos.h>
+#include <tcb-offsets.h>
 
 #ifdef UP
 # define LOCK
@@ -374,8 +375,7 @@ __pthread_cond_timedwait:
 #endif
 .LENDCODE:
 	.size	__pthread_cond_timedwait, .-__pthread_cond_timedwait
-versioned_symbol (libpthread, __pthread_cond_timedwait, pthread_cond_timedwait,
-		  GLIBC_2_3_2)
+weak_alias(__pthread_cond_timedwait, pthread_cond_timedwait)
 
 
 	.section .eh_frame,"a",@progbits

+ 2 - 2
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S

@@ -19,6 +19,7 @@
 
 #include <sysdep.h>
 #include <lowlevelcond.h>
+#include <tcb-offsets.h>
 
 #ifdef UP
 # define LOCK
@@ -348,8 +349,7 @@ __pthread_cond_wait:
 	jmp	14b
 .LENDCODE:
 	.size	__pthread_cond_wait, .-__pthread_cond_wait
-versioned_symbol (libpthread, __pthread_cond_wait, pthread_cond_wait,
-		  GLIBC_2_3_2)
+weak_alias(__pthread_cond_wait, pthread_cond_wait)
 
 
 	.section .eh_frame,"a",@progbits

+ 1 - 0
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S

@@ -20,6 +20,7 @@
 #include <sysdep.h>
 #include <lowlevelrwlock.h>
 #include <pthread-errnos.h>
+#include <tcb-offsets.h>
 
 
 #define FUTEX_WAIT		0

+ 1 - 0
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S

@@ -20,6 +20,7 @@
 #include <sysdep.h>
 #include <lowlevelrwlock.h>
 #include <pthread-errnos.h>
+#include <tcb-offsets.h>
 
 
 #define FUTEX_WAIT		0

+ 1 - 0
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S

@@ -20,6 +20,7 @@
 #include <sysdep.h>
 #include <lowlevelrwlock.h>
 #include <pthread-errnos.h>
+#include <tcb-offsets.h>
 
 
 #define FUTEX_WAIT		0

+ 1 - 0
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S

@@ -20,6 +20,7 @@
 #include <sysdep.h>
 #include <lowlevelrwlock.h>
 #include <pthread-errnos.h>
+#include <tcb-offsets.h>
 
 
 #define FUTEX_WAIT		0

+ 1 - 1
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_spin_unlock.S

@@ -1 +1 @@
-#include <nptl/sysdeps/x86_64/pthread_spin_unlock.S>
+#include <sysdeps/x86_64/pthread_spin_unlock.S>

+ 0 - 1
libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/sem_trywait.S

@@ -55,4 +55,3 @@ sem_trywait:
 	orl	$-1, %eax
 	retq
 	.size	sem_trywait,.-sem_trywait
-	versioned_symbol(libpthread, __new_sem_trywait, sem_trywait, GLIBC_2_1)