mirror of
https://github.com/golang/go
synced 2024-11-11 22:10:22 -07:00
runtime: update signature of reflectcall functions
reflectcall tail calls runtime.call{16,32,...} functions, so they have the same signature as reflectcall. It is important for them to have the correct arg map, because those functions, as well as the function being reflectcall'd, could move the stack. When that happens, its pointer arguments, in particular regArgs, need to be adjusted. Otherwise it will still point to the old stack, causing memory corruption. This only caused failures on the regabi builder because it is the only place where internal/abi.RegArgs is not a zero-sized type. May fix #44821. Change-Id: Iab400ea6b60c52360d0b43a793f6bfe50ca9989b Reviewed-on: https://go-review.googlesource.com/c/go/+/300154 Trust: Cherry Zhang <cherryyz@google.com> Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Michael Knyszek <mknyszek@google.com>
This commit is contained in:
parent
30c28bbf05
commit
bc489dd6d5
@ -318,33 +318,34 @@ func return0()
|
||||
|
||||
// in asm_*.s
|
||||
// not called directly; definitions here supply type information for traceback.
|
||||
func call16(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call32(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call64(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call128(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call256(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call512(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call1024(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call2048(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call4096(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call8192(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call16384(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call32768(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call65536(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call131072(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call262144(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call524288(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call1048576(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call2097152(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call4194304(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call8388608(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call16777216(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call33554432(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call67108864(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call134217728(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call268435456(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call536870912(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
func call1073741824(typ, fn, arg unsafe.Pointer, n, retoffset uint32)
|
||||
// These must have the same signature (arg pointer map) as reflectcall.
|
||||
func call16(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call32(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call64(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call128(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call256(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call512(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call1024(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call2048(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call4096(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call8192(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call16384(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call32768(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call65536(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call131072(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call262144(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call524288(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call1048576(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call2097152(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call4194304(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call8388608(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call16777216(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call33554432(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call67108864(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call134217728(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call268435456(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call536870912(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
func call1073741824(typ, fn, stackArgs unsafe.Pointer, stackArgsSize, stackRetOffset, frameSize uint32, regArgs *abi.RegArgs)
|
||||
|
||||
func systemstack_switch()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user