This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] PPC64 enable with-tls


Wouldn't it be better to use a global register variable and C arithmetic
for THREAD_SELF?  i.e.

register uintptr_t __thread_register asm ("13");
#define THREAD_SELF \
  ((pthread_descr) (__thread_register + 0x7000 + TLS_TCB_SIZE + TLS_PRE_TCB_SIZE))

Then THREAD_GETMEM(,foo) => THREAD_SELF->foo allows the compiler to combine
the constant register bias and the member offset in one insn.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]