mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-22 21:10:07 +00:00
050f7298e1
__tls_get_addr/___tls_get_addr is always defined in ld.so. There is no need to call them via PLT inside ld.so. This patch adds the hidden __tls_get_addr/___tls_get_addr aliases and calls them directly from _dl_tlsdesc_dynamic. There is no need to set up the EBX register in i386 _dl_tlsdesc_dynamic when calling the hidden ___tls_get_addr. * elf/dl-tls.c (__tls_get_addr): Provide the hidden definition if not defined. * sysdeps/i386/dl-tls.h (___tls_get_addr): Provide the hidden definition. * sysdeps/i386/dl-tlsdesc.S (_dl_tlsdesc_dynamic): Call the hidden ___tls_get_addr. * sysdeps/x86_64/dl-tlsdesc.S (_dl_tlsdesc_dynamic): Call the hidden __tls_get_addr. * sysdeps/generic/localplt.data (__tls_get_addr): Removed. * sysdeps/unix/sysv/linux/i386/localplt.data (___tls_get_addr): Likewise.
18 lines
562 B
Plaintext
18 lines
562 B
Plaintext
# See scripts/check-localplt.awk for how this file is processed.
|
|
# PLT use is required for the malloc family and for matherr because
|
|
# users can define their own functions and have library internals call them.
|
|
libc.so: calloc
|
|
libc.so: free
|
|
libc.so: malloc
|
|
libc.so: memalign
|
|
libc.so: realloc
|
|
libm.so: matherr
|
|
# The dynamic loader uses __libc_memalign internally to allocate aligned
|
|
# TLS storage. The other malloc family of functions are expected to allow
|
|
# user symbol interposition.
|
|
ld.so: __libc_memalign
|
|
ld.so: malloc
|
|
ld.so: calloc
|
|
ld.so: realloc
|
|
ld.so: free
|