diff options
author | Michael Munday <mike.munday@ibm.com> | 2020-02-20 17:46:08 +0000 |
---|---|---|
committer | Michael Munday <mike.munday@ibm.com> | 2020-02-26 13:11:53 +0000 |
commit | cb74dcc172de2779a2f65ea830f687156c98ad50 (patch) | |
tree | f94450c829e15288289bcf99f27b91ede70954eb /src/cmd/compile/internal/ssa/loopbce.go | |
parent | 44fe355694798b5e1c55fc087e697886e93e633e (diff) | |
download | go-cb74dcc172de2779a2f65ea830f687156c98ad50.tar.gz go-cb74dcc172de2779a2f65ea830f687156c98ad50.zip |
cmd/compile: remove Greater* and Geq* generic integer ops
The generic Greater and Geq ops can always be replaced with the Less and
Leq ops. This CL therefore removes them. This simplifies the compiler since
it reduces the number of operations that need handling in both code and in
rewrite rules. This will be especially true when adding control flow
optimizations such as the integer-in-range optimizations in CL 165998.
Change-Id: If0648b2b19998ac1bddccbf251283f3be4ec3040
Reviewed-on: https://go-review.googlesource.com/c/go/+/220417
Run-TryBot: Michael Munday <mike.munday@ibm.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
Diffstat (limited to 'src/cmd/compile/internal/ssa/loopbce.go')
-rw-r--r-- | src/cmd/compile/internal/ssa/loopbce.go | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/src/cmd/compile/internal/ssa/loopbce.go b/src/cmd/compile/internal/ssa/loopbce.go index d99b15b2b6..5a4bc1d60a 100644 --- a/src/cmd/compile/internal/ssa/loopbce.go +++ b/src/cmd/compile/internal/ssa/loopbce.go @@ -103,11 +103,6 @@ func findIndVar(f *Func) []indVar { fallthrough case OpLess64: ind, max = c.Args[0], c.Args[1] - case OpGeq64: - flags |= indVarMaxInc - fallthrough - case OpGreater64: - ind, max = c.Args[1], c.Args[0] default: continue } |