diff options
author | Ulrich Drepper <drepper@redhat.com> | 2003-09-22 19:51:38 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2003-09-22 19:51:38 +0000 |
commit | c0df57e1ce270466be342d9998f72633764b22dc (patch) | |
tree | ca78fbaf7ff455cda82f9764da9cbba54e258479 /nptl | |
parent | 9d08fbbb29a4a0866b4ff642893c7dd97575b56e (diff) | |
download | glibc-c0df57e1ce270466be342d9998f72633764b22dc.tar.gz glibc-c0df57e1ce270466be342d9998f72633764b22dc.tar.xz glibc-c0df57e1ce270466be342d9998f72633764b22dc.zip |
Update.
2003-09-22 Ulrich Drepper <drepper@redhat.com> * timezone/zdump.c: Update from tzcode2003c. * timezone/zic.c: Likewise. * timezone/leapseconds: Update from tzdata2003c.
Diffstat (limited to 'nptl')
-rw-r--r-- | nptl/ChangeLog | 4 | ||||
-rw-r--r-- | nptl/sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S | 16 |
2 files changed, 13 insertions, 7 deletions
diff --git a/nptl/ChangeLog b/nptl/ChangeLog index cda72ea2bd..e74dec5c36 100644 --- a/nptl/ChangeLog +++ b/nptl/ChangeLog @@ -1,5 +1,9 @@ 2003-09-22 Ulrich Drepper <drepper@redhat.com> + * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S + (__lll_mutex_lock_wait): Minor optimization to avoid one atomic + operation if possible. + * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Don't play tricks like jumping over the lock prefix. diff --git a/nptl/sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S b/nptl/sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S index c73970d45f..c5ec154af2 100644 --- a/nptl/sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S +++ b/nptl/sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S @@ -41,16 +41,18 @@ .hidden __lll_mutex_lock_wait .align 16 __lll_mutex_lock_wait: - pushl %esi - pushl %ebx pushl %edx + pushl %ebx + pushl %esi + movl $2, %edx movl %ecx, %ebx xorl %esi, %esi /* No timeout. */ xorl %ecx, %ecx /* movl $FUTEX_WAIT, %ecx */ - movl $2, %edx -1: +1: cmpl %edx, %eax /* NB: %edx == 2 */ + je 3f + movl $1, %eax LOCK cmpxchgl %edx, (%ebx) @@ -58,7 +60,7 @@ __lll_mutex_lock_wait: testl %eax, %eax je 2f - movl $SYS_futex, %eax +3: movl $SYS_futex, %eax ENTER_KERNEL xorl %eax, %eax @@ -67,9 +69,9 @@ __lll_mutex_lock_wait: jnz,pn 1b - popl %edx - popl %ebx popl %esi + popl %ebx + popl %edx ret .size __lll_mutex_lock_wait,.-__lll_mutex_lock_wait |