]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: do not reuse dead value in expand_calls pass
authorCherry Mui <cherryyz@google.com>
Tue, 12 Oct 2021 16:38:42 +0000 (12:38 -0400)
committerCherry Mui <cherryyz@google.com>
Tue, 12 Oct 2021 18:00:16 +0000 (18:00 +0000)
commit6e0adde1e9467f5a0b9bdbe3d64f9093981ba5df
tree13f592380b175b28b80955e7d8bfb5eb0fa9bbf2
parent36a265a625a8320fea93aad62da4003b2cc54f72
cmd/compile: do not reuse dead value in expand_calls pass

We reuse a value for the same selector on the same arg. But if the
value is already marked dead, don't reuse it. A use of an
OpInvalid will confuse the compiler.

Fixes #48916.

Change-Id: I15b9e15b49f6e1991fe91df246cd12a193385e85
Reviewed-on: https://go-review.googlesource.com/c/go/+/355409
Trust: Cherry Mui <cherryyz@google.com>
Run-TryBot: Cherry Mui <cherryyz@google.com>
Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Reviewed-by: David Chase <drchase@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
src/cmd/compile/internal/ssa/expand_calls.go
test/fixedbugs/issue48916.go [new file with mode: 0644]