mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
[dev.typeparams] reflect: implement register ABI for MakeFunc etc. on ARM64
Implement register ABI for reflect.MakeFunc and method Value Call on ARM64. Change-Id: I5487febb9ea764af5ccf5d7c94858ab0acec7cac Reviewed-on: https://go-review.googlesource.com/c/go/+/323936 Trust: Cherry Mui <cherryyz@google.com> Run-TryBot: Cherry Mui <cherryyz@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Michael Knyszek <mknyszek@google.com>
This commit is contained in:
parent
2e4b79949f
commit
0c123cdf8b
2 changed files with 54 additions and 13 deletions
|
|
@ -1318,11 +1318,11 @@ func getStackMap(frame *stkframe, cache *pcvalueCache, debug bool) (locals, args
|
|||
}
|
||||
|
||||
// stack objects.
|
||||
if GOARCH == "amd64" && unsafe.Sizeof(abi.RegArgs{}) > 0 && frame.argmap != nil {
|
||||
if (GOARCH == "amd64" || GOARCH == "arm64") && unsafe.Sizeof(abi.RegArgs{}) > 0 && frame.argmap != nil {
|
||||
// argmap is set when the function is reflect.makeFuncStub or reflect.methodValueCall.
|
||||
// We don't actually use argmap in this case, but we need to fake the stack object
|
||||
// record for these frames which contain an internal/abi.RegArgs at a hard-coded offset
|
||||
// on amd64.
|
||||
// record for these frames which contain an internal/abi.RegArgs at a hard-coded offset.
|
||||
// This offset matches the assembly code on amd64 and arm64.
|
||||
objs = methodValueCallFrameObjs
|
||||
} else {
|
||||
p := funcdata(f, _FUNCDATA_StackObjects)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue