From 80e5c3b8b556c9c8010c0efd4e8d40f595743ee6 Mon Sep 17 00:00:00 2001 From: Josh Bleecher Snyder Date: Thu, 16 Apr 2020 22:05:35 -0700 Subject: [PATCH] cmd/compile: remove superfluous SetBounded call The call does nothing when applied to an OLSH node. It would be unnecessary anyway, since we're shifting by a small constant. Passes toolstash-check. Change-Id: If858711f1704f44637fa0f6a4c66cbaad6db24b8 Reviewed-on: https://go-review.googlesource.com/c/go/+/228699 Run-TryBot: Josh Bleecher Snyder TryBot-Result: Gobot Gobot Reviewed-by: Matthew Dempsky Reviewed-by: Cuong Manh Le --- src/cmd/compile/internal/gc/walk.go | 1 - 1 file changed, 1 deletion(-) diff --git a/src/cmd/compile/internal/gc/walk.go b/src/cmd/compile/internal/gc/walk.go index bf12455a5d4..06910450ff7 100644 --- a/src/cmd/compile/internal/gc/walk.go +++ b/src/cmd/compile/internal/gc/walk.go @@ -840,7 +840,6 @@ opswitch: n.Left = cheapexpr(n.Left, init) // byteindex widens n.Left so that the multiplication doesn't overflow. index := nod(OLSH, byteindex(n.Left), nodintconst(3)) - index.SetBounded(true) if thearch.LinkArch.ByteOrder == binary.BigEndian { index = nod(OADD, index, nodintconst(7)) }