diff options
Diffstat (limited to 'src/runtime/sys_linux_amd64.s')
| -rw-r--r-- | src/runtime/sys_linux_amd64.s | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/runtime/sys_linux_amd64.s b/src/runtime/sys_linux_amd64.s index b709f77060..5c300f553d 100644 --- a/src/runtime/sys_linux_amd64.s +++ b/src/runtime/sys_linux_amd64.s @@ -605,10 +605,8 @@ TEXT runtime·sigaltstack(SB),NOSPLIT,$-8 // set tls base to DI TEXT runtime·settls(SB),NOSPLIT,$32 #ifdef GOOS_android - // Same as in sys_darwin_386.s:/ugliness, different constant. - // DI currently holds m->tls, which must be fs:0x1d0. - // See cgo/gcc_android_amd64.c for the derivation of the constant. - SUBQ $0x1d0, DI // In android, the tls base + // Android stores the TLS offset in runtime·tls_g. + SUBQ runtime·tls_g(SB), DI #else ADDQ $8, DI // ELF wants to use -8(FS) #endif |
