[PATCH] D16201: [ELF/AArch64] - Implemented set of R_AARCH64_TLSDESC_* relocations.
Adhemerval Zanella via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 10 02:09:09 PST 2016
zatrazz added a comment.
This patch is required because clang only implements the tlsdesc dialect for aarch64. GCC implements both dialects, so you can:
$ gcc test.c -fPIC -o test.o -c -mtls-dialect=trad
$ readelf -r test.o
Relocation section '.rela.text' at offset 0x248 contains 3 entries:
Offset Info Type Sym. Value Sym. Name + Addend
000000000008 000a00000201 R_AARCH64_TLSGD_A 0000000000000000 foo + 0
00000000000c 000a00000202 R_AARCH64_TLSGD_A 0000000000000000 foo + 0
000000000010 000c0000011b R_AARCH64_CALL26 0000000000000000 __tls_get_addr + 0
Also, even is clang implements the traditional TLS dialect for aarch64, we do need to support tlsdesc one (and it is the default for aarch64).
http://reviews.llvm.org/D16201
More information about the llvm-commits
mailing list