aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/tls_arm.s
diff options
context:
space:
mode:
authorBrad Fitzpatrick <bradfitz@golang.org>2019-10-08 19:19:13 +0000
committerBrad Fitzpatrick <bradfitz@golang.org>2019-10-09 06:14:44 +0000
commita38a917aee626a9b9d5ce2b93964f586bf759ea0 (patch)
treeb5259bc8fc8ad6b7955a3c04aba1b21053cfb30c /src/runtime/tls_arm.s
parent2197321db1dd997165c0091ba2bcb3b6be7633d0 (diff)
downloadgo-a38a917aee626a9b9d5ce2b93964f586bf759ea0.tar.gz
go-a38a917aee626a9b9d5ce2b93964f586bf759ea0.zip
all: remove the nacl port (part 1)
You were a useful port and you've served your purpose. Thanks for all the play. A subsequent CL will remove amd64p32 (including assembly files and toolchain bits) and remaining bits. The amd64p32 removal will be separated into its own CL in case we want to support the Linux x32 ABI in the future and want our old amd64p32 support as a starting point. Updates #30439 Change-Id: Ia3a0c7d49804adc87bf52a4dea7e3d3007f2b1cd Reviewed-on: https://go-review.googlesource.com/c/go/+/199499 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/runtime/tls_arm.s')
-rw-r--r--src/runtime/tls_arm.s13
1 files changed, 0 insertions, 13 deletions
diff --git a/src/runtime/tls_arm.s b/src/runtime/tls_arm.s
index 350089abc6..bed7891368 100644
--- a/src/runtime/tls_arm.s
+++ b/src/runtime/tls_arm.s
@@ -33,11 +33,6 @@
// runtime.mcall assumes this function only clobbers R0 and R11.
// Returns with g in R0.
TEXT runtime·save_g(SB),NOSPLIT|NOFRAME,$0
-#ifdef GOOS_nacl
- // nothing to do as nacl/arm does not use TLS at all.
- MOVW g, R0 // preserve R0 across call to setg<>
- RET
-#else
// If the host does not support MRC the linker will replace it with
// a call to runtime.read_tls_fallback which jumps to __kuser_get_tls.
// The replacement function saves LR in R11 over the call to read_tls_fallback.
@@ -48,16 +43,11 @@ TEXT runtime·save_g(SB),NOSPLIT|NOFRAME,$0
MOVW g, 0(R0)
MOVW g, R0 // preserve R0 across call to setg<>
RET
-#endif
// load_g loads the g register from pthread-provided
// thread-local memory, for use after calling externally compiled
// ARM code that overwrote those registers.
TEXT runtime·load_g(SB),NOSPLIT,$0
-#ifdef GOOS_nacl
- // nothing to do as nacl/arm does not use TLS at all.
- RET
-#else
// See save_g
MRC 15, 0, R0, C13, C0, 3 // fetch TLS base pointer
BIC $3, R0 // Darwin/ARM might return unaligned pointer
@@ -65,7 +55,6 @@ TEXT runtime·load_g(SB),NOSPLIT,$0
ADD R11, R0
MOVW 0(R0), g
RET
-#endif
// This is called from rt0_go, which runs on the system stack
// using the initial stack allocated by the OS.
@@ -78,7 +67,6 @@ TEXT runtime·load_g(SB),NOSPLIT,$0
// Declare a dummy word ($4, not $0) to make sure the
// frame is 8 bytes and stays 8-byte-aligned.
TEXT runtime·_initcgo(SB),NOSPLIT,$4
-#ifndef GOOS_nacl
// if there is an _cgo_init, call it.
MOVW _cgo_init(SB), R4
CMP $0, R4
@@ -93,7 +81,6 @@ TEXT runtime·_initcgo(SB),NOSPLIT,$4
MOVW $setg_gcc<>(SB), R1 // arg 1: setg
MOVW g, R0 // arg 0: G
BL (R4) // will clobber R0-R3
-#endif
nocgo:
RET