mirror of
git://git.musl-libc.org/musl
synced 2025-02-10 07:57:06 +00:00
the only part of TP_ADJ that was not uniquely determined by TLS_ABOVE_TP was the 0x7000 adjustment used mainly on mips and powerpc variants.
9 lines
161 B
C
9 lines
161 B
C
static inline struct pthread *__pthread_self()
|
|
{
|
|
struct pthread *self;
|
|
__asm__ ("mov %%fs:0,%0" : "=r" (self) );
|
|
return self;
|
|
}
|
|
|
|
#define MC_PC gregs[REG_RIP]
|