mirror of
git://sourceware.org/git/glibc.git
synced 2025-03-06 20:58:33 +01:00
s390: Define TLS_DTV_OFFSET instead of GET_ADDR_OFFSET
This will be used in __tls_get_addr to adjust the returned pointer value. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
This commit is contained in:
parent
ceae7e2770
commit
91ee75abcf
1 changed files with 3 additions and 3 deletions
|
@ -24,6 +24,9 @@ typedef struct
|
||||||
unsigned long int ti_offset;
|
unsigned long int ti_offset;
|
||||||
} tls_index;
|
} tls_index;
|
||||||
|
|
||||||
|
/* The DTV stores absolute addresses, but __tls_get_addr must return
|
||||||
|
TP-relative addresses. */
|
||||||
|
#define TLS_DTV_OFFSET (-(unsigned long int) __builtin_thread_pointer ())
|
||||||
|
|
||||||
#ifdef SHARED
|
#ifdef SHARED
|
||||||
|
|
||||||
|
@ -89,9 +92,6 @@ __tls_get_offset:\n\
|
||||||
extern void *__tls_get_addr_internal (tls_index *ti);
|
extern void *__tls_get_addr_internal (tls_index *ti);
|
||||||
# endif /* !IS_IN (rtld) */
|
# endif /* !IS_IN (rtld) */
|
||||||
|
|
||||||
# define GET_ADDR_OFFSET \
|
|
||||||
(ti->ti_offset - (unsigned long) __builtin_thread_pointer ())
|
|
||||||
|
|
||||||
/* Use the privately exported __tls_get_addr_internal instead of
|
/* Use the privately exported __tls_get_addr_internal instead of
|
||||||
__tls_get_offset in order to avoid the __tls_get_offset special
|
__tls_get_offset in order to avoid the __tls_get_offset special
|
||||||
linkage requiring the GOT pointer to be set up in r12. The
|
linkage requiring the GOT pointer to be set up in r12. The
|
||||||
|
|
Loading…
Add table
Reference in a new issue