go/src/reflect
Cherry Mui 23adc139bf reflect: keep pointer in aggregate-typed args live in Call
When register ABI is used, reflect.Value.Call prepares the call
arguments in a memory representation of the argument registers.
It has special handling to keep the pointers in arguments live.
Currently, this handles pointer-typed arguments. But when an
argument is an aggregate-type that contains pointers and passed
in registers, it currently doesn't keep the pointers live. Do
so in this CL.

May fix #49363.

Change-Id: Ic6a0c5fdf9375ef02f7c03fbe9345e2e98c9353d
Reviewed-on: https://go-review.googlesource.com/c/go/+/363358
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>
2021-11-12 14:56:58 +00:00
..
internal
abi.go all: use reflect.{Pointer,PointerTo} 2021-10-26 14:24:17 +00:00
abi_test.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
all_test.go reflect: keep pointer in aggregate-typed args live in Call 2021-11-12 14:56:58 +00:00
asm_386.s
asm_amd64.s
asm_arm.s
asm_arm64.s
asm_mips64x.s all: remove more leftover // +build lines 2021-11-06 10:24:44 +00:00
asm_mipsx.s all: remove more leftover // +build lines 2021-11-06 10:24:44 +00:00
asm_ppc64x.s all: remove more leftover // +build lines 2021-11-06 10:24:44 +00:00
asm_riscv64.s
asm_s390x.s
asm_wasm.s
deepequal.go all: use reflect.{Pointer,PointerTo} 2021-10-26 14:24:17 +00:00
example_test.go reflect: add example for FieldByIndex 2021-08-22 13:14:19 +00:00
export_test.go reflect: fix methodValueCall code pointer mismatched 2021-10-19 16:19:27 +00:00
float32reg_generic.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
float32reg_ppc64x.s all: remove more leftover // +build lines 2021-11-06 10:24:44 +00:00
makefunc.go reflect: fix methodValueCall code pointer mismatched 2021-10-19 16:19:27 +00:00
set_test.go reflect: add Value.UnsafePointer 2021-10-18 16:33:42 +00:00
stubs_ppc64x.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
swapper.go [dev.typeparams] reflect: use goarch.PtrSize instead of the duplicated ptrSize [generated] 2021-06-17 21:29:22 +00:00
tostring_test.go all: use reflect.{Pointer,PointerTo} 2021-10-26 14:24:17 +00:00
type.go reflect: undeprecate Ptr, PtrTo 2021-10-28 03:44:12 +00:00
value.go reflect: keep pointer in aggregate-typed args live in Call 2021-11-12 14:56:58 +00:00
visiblefields.go all: use reflect.{Pointer,PointerTo} 2021-10-26 14:24:17 +00:00
visiblefields_test.go reflect: add FieldByIndexErr 2021-10-29 02:11:42 +00:00