diff options
Diffstat (limited to 'sysdeps/unix/x86_64/sysdep.S')
-rw-r--r-- | sysdeps/unix/x86_64/sysdep.S | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sysdeps/unix/x86_64/sysdep.S b/sysdeps/unix/x86_64/sysdep.S index a54c151013..b0580a39ae 100644 --- a/sysdeps/unix/x86_64/sysdep.S +++ b/sysdeps/unix/x86_64/sysdep.S @@ -42,8 +42,12 @@ syscall_error: notb: #endif #if USE_TLS && HAVE___THREAD - movq C_SYMBOL_NAME(errno)@GOTTPOFF(%rip), %rcx +# ifdef PIC + movq C_SYMBOL_NAME(errno@GOTTPOFF)(%rip), %rcx movl %eax, %fs:0(%rcx) +# else + movl %eax, %fs:C_SYMBOL_NAME(errno@TPOFF) +# endif #elif !defined PIC # ifndef _LIBC_REENTRANT movl %eax, C_SYMBOL_NAME(errno) |