2 #define ARM_PC_OFFSET "4"
4 #define ARM_PC_OFFSET "8"
9 void *tp = __builtin_thread_pointer (); \
14 "1: .word " #x "(tpoff); " \
16 : "=&r" (__result) : "r" (tp)); \
22 void *tp = __builtin_thread_pointer (); \
24 "3: add %0, pc, %0;" \
29 "1: .word " #x "(gottpoff) + (. - 3b - 4); " \
31 : "=&r" (__result) : "r" (tp)); \
36 void *tp = __builtin_thread_pointer (); \
38 "3: ldr %0, [pc, %0];" \
42 "1: .word " #x "(gottpoff) + (. - 3b - 8); " \
44 : "=&r" (__result) : "r" (tp)); \
51 extern void *__tls_get_addr (void *); \
53 "1: add %0, pc, %0; " \
56 "2: .word " #x "(tlsldm) + (. - 1b - "ARM_PC_OFFSET"); " \
59 __result = (char *)__tls_get_addr (__result); \
63 "1: .word " #x "(tlsldo); " \
66 (int *) (__result + __offset); })
70 extern void *__tls_get_addr (void *); \
72 "1: add %0, pc, %0; " \
75 "2: .word " #x "(tlsgd) + (. - 1b - "ARM_PC_OFFSET"); " \
78 (int *)__tls_get_addr (__result); })