-
Notifications
You must be signed in to change notification settings - Fork 14.9k
Open
Labels
Description
lld does not support TLSDESC (-mtls-dialect=gnu2
) for arm. We are currently looking to make -mtls-dialect=gnu2
the default for x86 in GCC. ARM may follow depending on how that goes.
extern __thread int tlsdesc;
int get(void) { return tlsdesc; }
$ gcc a.c -shared -fuse-ld=lld -mtls-dialect=gnu2 -fPIC
ld.lld: error: /tmp/ccvULiJP.o:(function get: .text+0xc): unknown relocation (91) against symbol tlsdesc
ld.lld: error: internal linker error: cannot read addend for relocation R_ARM_TLS_CALL
ld.lld: error: /tmp/ccvULiJP.o:(function get: .text+0x24): unknown relocation (90) against symbol tlsdesc
ld.lld: error: internal linker error: cannot read addend for relocation R_ARM_TLS_GOTDESC
collect2: error: ld returned 1 exit status