mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
[dev.typeparams] Revert "[dev.typeparams] runtime,cmd/compile,cmd/link: replace jmpdefer with a loop"
This reverts CL 227652. I'm reverting CL 337651 and this builds on top of it. Change-Id: I03ce363be44c2a3defff2e43e7b1aad83386820d Reviewed-on: https://go-review.googlesource.com/c/go/+/338709 Trust: Austin Clements <austin@google.com> Run-TryBot: Austin Clements <austin@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Cherry Mui <cherryyz@google.com>
This commit is contained in:
parent
40e561d933
commit
e3e9f0bb2d
31 changed files with 324 additions and 39 deletions
|
|
@ -24,6 +24,7 @@ func Init(arch *ssagen.ArchInfo) {
|
|||
|
||||
arch.ZeroRange = zeroRange
|
||||
arch.Ginsnop = ginsnop
|
||||
arch.Ginsnopdefer = ginsnop
|
||||
|
||||
arch.SSAMarkMoves = ssaMarkMoves
|
||||
arch.SSAGenValue = ssaGenValue
|
||||
|
|
@ -125,11 +126,7 @@ func ssaGenValue(s *ssagen.State, v *ssa.Value) {
|
|||
case ssa.OpWasmLoweredStaticCall, ssa.OpWasmLoweredClosureCall, ssa.OpWasmLoweredInterCall:
|
||||
s.PrepareCall(v)
|
||||
if call, ok := v.Aux.(*ssa.AuxCall); ok && call.Fn == ir.Syms.Deferreturn {
|
||||
// The runtime needs to inject jumps to
|
||||
// deferreturn calls using the address in
|
||||
// _func.deferreturn. Hence, the call to
|
||||
// deferreturn must itself be a resumption
|
||||
// point so it gets a target PC.
|
||||
// add a resume point before call to deferreturn so it can be called again via jmpdefer
|
||||
s.Prog(wasm.ARESUMEPOINT)
|
||||
}
|
||||
if v.Op == ssa.OpWasmLoweredClosureCall {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue