diff options
author | Rich Felker <dalias@aerifal.cx> | 2011-02-15 03:56:52 -0500 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2011-02-15 03:56:52 -0500 |
commit | 7b2dd2235dd0db3a2f71e25d1c0925e0348e1996 (patch) | |
tree | 26cab4bb4f2bff3b4cf8ccb2c0e497cf9631c893 /arch | |
parent | 0b2006c8fea021b7fa1fd267bf270cb8c279f230 (diff) | |
download | musl-7b2dd2235dd0db3a2f71e25d1c0925e0348e1996.tar.gz musl-7b2dd2235dd0db3a2f71e25d1c0925e0348e1996.tar.bz2 musl-7b2dd2235dd0db3a2f71e25d1c0925e0348e1996.tar.xz musl-7b2dd2235dd0db3a2f71e25d1c0925e0348e1996.zip |
finish unifying thread register handling in preparation for porting
Diffstat (limited to 'arch')
-rw-r--r-- | arch/i386/pthread_arch.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/i386/pthread_arch.h b/arch/i386/pthread_arch.h new file mode 100644 index 00000000..155b4847 --- /dev/null +++ b/arch/i386/pthread_arch.h @@ -0,0 +1,6 @@ +static inline struct pthread *__pthread_self() +{ + struct pthread *self; + __asm__ ("movl %%gs:0,%0" : "=r" (self) ); + return self; +} |