diff options
| author | Pawel Sikora <pluto@pld-linux.org> | 2004-11-10 21:36:11 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2004-11-10 21:36:11 -0800 |
| commit | d0efa0ccde10398f851489ffc5b1581162a67cbb (patch) | |
| tree | 9de393eeb55d853a94d642599c28ce1aa3e9cc86 /include | |
| parent | 81dc6cfd730838baace55ece1788577ad7c7ee6b (diff) | |
[PATCH] x86: optimize stack pointer access (reduce register usage)
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include')
| -rw-r--r-- | include/asm-i386/thread_info.h | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/include/asm-i386/thread_info.h b/include/asm-i386/thread_info.h index 9eba8cbd0d4a..9afee94ac026 100644 --- a/include/asm-i386/thread_info.h +++ b/include/asm-i386/thread_info.h @@ -92,12 +92,7 @@ static inline struct thread_info *current_thread_info(void) } /* how to get the current stack pointer from C */ -static inline unsigned long current_stack_pointer(void) -{ - unsigned long ti; - __asm__("movl %%esp,%0; ":"=r" (ti) : ); - return ti; -} +register unsigned long current_stack_pointer asm("esp"); /* thread information allocation */ #ifdef CONFIG_DEBUG_STACK_USAGE |
