diff options
Diffstat (limited to 'nptl/sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S')
-rw-r--r-- | nptl/sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S b/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S index e1593f32ff..fa8125dd87 100644 --- a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S +++ b/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S @@ -1,4 +1,4 @@ -/* Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. +/* Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper <drepper@redhat.com>, 2002. @@ -63,9 +63,14 @@ pthread_barrier_wait: /* Wait for the remaining threads. The call will return immediately if the CURR_EVENT memory has meanwhile been changed. */ -7: xorq %rsi, %rsi /* movq $FUTEX_WAIT, %rsi */ +7: +#if FUTEX_WAIT == 0 + xorl %esi, %esi +#else + movl $FUTEX_WAIT, %esi +#endif xorq %r10, %r10 -8: movq $SYS_futex, %rax +8: movl $SYS_futex, %eax syscall /* Don't return on spurious wakeups. The syscall does not change @@ -110,8 +115,8 @@ pthread_barrier_wait: /* Wake up all waiters. The count is a signed number in the kernel so 0x7fffffff is the highest value. */ movl $0x7fffffff, %edx - movq $FUTEX_WAKE, %rsi - movq $SYS_futex, %rax + movl $FUTEX_WAKE, %esi + movl $SYS_futex, %eax syscall /* Increment LEFT. If this brings the count back to the |