aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/duff_amd64.s
diff options
context:
space:
mode:
authorThan McIntosh <thanm@google.com>2020-10-14 08:36:11 -0400
committerThan McIntosh <thanm@google.com>2020-10-29 15:13:09 +0000
commit50af50d136551e2009b2b52e829570536271cdaa (patch)
treeea00744bee71fee9f096928404082e6748e57b95 /src/runtime/duff_amd64.s
parentecb79e8afa7811fd23b2e550a2bc5b22ea0aa82d (diff)
downloadgo-50af50d136551e2009b2b52e829570536271cdaa.tar.gz
go-50af50d136551e2009b2b52e829570536271cdaa.zip
reflect,runtime: use internal ABI for selected ASM routines
Change the definitions of selected runtime assembly routines from ABI0 (the default) to ABIInternal. The ABIInternal def is intended to indicate that these functions don't follow the existing Go runtime ABI. In addition, convert the assembly reference to runtime.main (from runtime.mainPC) to ABIInternal. Finally, for functions such as "runtime.duffzero" that are called directly from generated code, make sure that the compiler looks up the correct ABI version. This is intended to support the register abi work, however these changes should not have any issues even when GOEXPERIMENT=regabi is not in effect. Updates #27539, #40724. Change-Id: I9846f8dcaccc95718cf2e61a18b7e924a0677e4c Reviewed-on: https://go-review.googlesource.com/c/go/+/262319 Run-TryBot: Than McIntosh <thanm@google.com> TryBot-Result: Go Bot <gobot@golang.org> Trust: Than McIntosh <thanm@google.com> Reviewed-by: Cherry Zhang <cherryyz@google.com>
Diffstat (limited to 'src/runtime/duff_amd64.s')
-rw-r--r--src/runtime/duff_amd64.s4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/duff_amd64.s b/src/runtime/duff_amd64.s
index 44dc75d297..2ff5bf6dbc 100644
--- a/src/runtime/duff_amd64.s
+++ b/src/runtime/duff_amd64.s
@@ -4,7 +4,7 @@
#include "textflag.h"
-TEXT runtime·duffzero(SB), NOSPLIT, $0-0
+TEXT runtime·duffzero<ABIInternal>(SB), NOSPLIT, $0-0
MOVUPS X0,(DI)
MOVUPS X0,16(DI)
MOVUPS X0,32(DI)
@@ -103,7 +103,7 @@ TEXT runtime·duffzero(SB), NOSPLIT, $0-0
RET
-TEXT runtime·duffcopy(SB), NOSPLIT, $0-0
+TEXT runtime·duffcopy<ABIInternal>(SB), NOSPLIT, $0-0
MOVUPS (SI), X0
ADDQ $16, SI
MOVUPS X0, (DI)