]> Cypherpunks repositories - gostls13.git/commit
[release-branch.go1.16] cmd/compile: mark R16, R17 clobbered for non-standard calls...
authorCherry Zhang <cherryyz@google.com>
Fri, 28 Jun 2019 13:30:36 +0000 (09:30 -0400)
committerCarlos Amedee <carlos@golang.org>
Mon, 2 Aug 2021 22:28:53 +0000 (22:28 +0000)
commit8b6ae9be125dd7c66123686fe339203f0661d92c
tree56a10e33b77b2cbbe7ef6cee1352cec6c5095db3
parent3d5afa9610c5b0e45783868ae964152855a736ac
[release-branch.go1.16] cmd/compile: mark R16, R17 clobbered for non-standard calls on ARM64

On ARM64, (external) linker generated trampoline may clobber R16
and R17. In CL 183842 we change Duff's devices not to use those
registers. However, this is not enough. The register allocator
also needs to know that these registers may be clobbered in any
calls that don't follow the standard Go calling convention. This
include Duff's devices and the write barrier.

Fixes #46928.
Updates #32773.

Change-Id: Ia52a891d9bbb8515c927617dd53aee5af5bd9aa4
Reviewed-on: https://go-review.googlesource.com/c/go/+/184437
Run-TryBot: Cherry Zhang <cherryyz@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Meng Zhuo <mzh@golangcn.org>
Reviewed-by: Keith Randall <khr@golang.org>
Trust: Meng Zhuo <mzh@golangcn.org>
(cherry picked from commit 11b4aee05bfe83513cf08f83091e5aef8b33e766)
Reviewed-on: https://go-review.googlesource.com/c/go/+/331029
Trust: Cherry Mui <cherryyz@google.com>
Run-TryBot: Cherry Mui <cherryyz@google.com>
src/cmd/compile/internal/ssa/gen/ARM64Ops.go
src/cmd/compile/internal/ssa/opGen.go
src/runtime/asm_arm64.s