summaryrefslogtreecommitdiff
path: root/sysdeps
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2007-03-03 23:57:37 +0000
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2007-03-03 23:57:37 +0000
commit47f99033b358fb41d7c9f8f2b2f8aa221cbcc387 (patch)
tree83fe19fc566515bea910155e45996100483d355f /sysdeps
parentc9f6661d48de1d24a21093f70031bc9a055a6a33 (diff)
2006-03-04 Samuel Thibault <samuel.thibault@ens-lyon.org>
* libpthread/sysdeps/i386/machine-sp.h (thread_stack_pointer): Optimize esp read. * libpthread/i386/cthreads.h (cthread_sp): Likewise.
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/i386/machine-sp.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/sysdeps/i386/machine-sp.h b/sysdeps/i386/machine-sp.h
index 536f690..945a36b 100644
--- a/sysdeps/i386/machine-sp.h
+++ b/sysdeps/i386/machine-sp.h
@@ -23,8 +23,7 @@
/* Return the current stack pointer. */
#define __thread_stack_pointer() ({ \
- void *__sp__; \
- __asm__ ("movl %%esp, %0" : "=r" (__sp__)); \
+ register void *__sp__ asm("esp"); \
__sp__; \
})