]> Cypherpunks repositories - gostls13.git/commit
[release-branch.go1.18] cmd/compile: fix prove pass when upper condition is <= maxint
authorKeith Randall <khr@golang.org>
Wed, 29 Jun 2022 20:22:59 +0000 (13:22 -0700)
committerHeschi Kreinick <heschi@google.com>
Wed, 6 Jul 2022 19:44:10 +0000 (19:44 +0000)
commit5f2dff9b66840d0750637308b8512c5b69cbad0b
tree64cc21dd347a9474292e4b3dde81c61682faa642
parent2f43de6da0898d3f7031dee0b7a80a219df3dfee
[release-branch.go1.18] cmd/compile: fix prove pass when upper condition is <= maxint

When the terminating condition is <= X, we need to make sure that
X+step doesn't overflow.

Fixes #53618

Change-Id: I36e5384d05b4d7168e48db6094200fcae409bfe5
Reviewed-on: https://go-review.googlesource.com/c/go/+/415219
Reviewed-by: Than McIntosh <thanm@google.com>
Run-TryBot: David Chase <drchase@google.com>
Reviewed-by: David Chase <drchase@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Keith Randall <khr@golang.org>
(cherry picked from commit 31b8c23c5702f129aca9241bbb2132c90b1929cc)
Reviewed-on: https://go-review.googlesource.com/c/go/+/415414
Reviewed-by: Keith Randall <khr@google.com>
src/cmd/compile/internal/ssa/loopbce.go
test/fixedbugs/issue53600.go [new file with mode: 0644]
test/fixedbugs/issue53600.out [new file with mode: 0644]