aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/compile/internal/ssa/phiopt.go
diff options
context:
space:
mode:
authorJosh Bleecher Snyder <josharian@gmail.com>2020-08-13 12:39:04 -0700
committerJosh Bleecher Snyder <josharian@gmail.com>2020-08-13 22:59:31 +0000
commitcde5fd1c0f8c40804bfd942eec1e2d69bccf4e13 (patch)
tree32dd1018b3e816103c82a805579cbfe0c1d54533 /src/cmd/compile/internal/ssa/phiopt.go
parent7d7bd5abc7f7ac901830b79496f63ce86895e262 (diff)
downloadgo-cde5fd1c0f8c40804bfd942eec1e2d69bccf4e13.tar.gz
go-cde5fd1c0f8c40804bfd942eec1e2d69bccf4e13.zip
cmd/compile: correct type of CvtBoolToUint8 values
Fixes #40746 Change-Id: I539f07d1f958dacee87d846171a8889d03182d25 Reviewed-on: https://go-review.googlesource.com/c/go/+/248397 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Keith Randall <khr@golang.org>
Diffstat (limited to 'src/cmd/compile/internal/ssa/phiopt.go')
-rw-r--r--src/cmd/compile/internal/ssa/phiopt.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cmd/compile/internal/ssa/phiopt.go b/src/cmd/compile/internal/ssa/phiopt.go
index 8643fa584c..db7b02275c 100644
--- a/src/cmd/compile/internal/ssa/phiopt.go
+++ b/src/cmd/compile/internal/ssa/phiopt.go
@@ -154,7 +154,7 @@ func phioptint(v *Value, b0 *Block, reverse int) {
}
v.AddArg(a)
- cvt := v.Block.NewValue1(v.Pos, OpCvtBoolToUint8, a.Type, a)
+ cvt := v.Block.NewValue1(v.Pos, OpCvtBoolToUint8, v.Block.Func.Config.Types.UInt8, a)
switch v.Type.Size() {
case 1:
v.reset(OpCopy)