aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/compile/internal/ssa/lower.go
diff options
context:
space:
mode:
authorKeith Randall <khr@golang.org>2016-01-05 14:56:26 -0800
committerKeith Randall <khr@golang.org>2016-01-13 18:42:00 +0000
commit3425295e915bc16236f2c021317705aca34319af (patch)
tree3d9adc97103ae2c92c95f777ca1339d0797a6bdd /src/cmd/compile/internal/ssa/lower.go
parent9094e3ada2de3cc8129b70730c2c0782a4040201 (diff)
downloadgo-3425295e915bc16236f2c021317705aca34319af.tar.gz
go-3425295e915bc16236f2c021317705aca34319af.zip
[dev.ssa] cmd/compile: clean up comparisons
Add new constant-flags opcodes. These can be generated from comparisons that we know the result of, like x&31 < 32. Constant-fold the constant-flags opcodes into all flag users. Reorder some CMPxconst args so they read in the comparison direction. Reorg deadcode removal a bit - it needs to remove the OpCopy ops it generates when strength-reducing Phi ops. So it needs to splice out all the dead blocks and do a copy elimination before it computes live values. Change-Id: Ie922602033592ad8212efe4345394973d3b94d9f Reviewed-on: https://go-review.googlesource.com/18267 Run-TryBot: Keith Randall <khr@golang.org> Reviewed-by: David Chase <drchase@google.com>
Diffstat (limited to 'src/cmd/compile/internal/ssa/lower.go')
-rw-r--r--src/cmd/compile/internal/ssa/lower.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cmd/compile/internal/ssa/lower.go b/src/cmd/compile/internal/ssa/lower.go
index bf3c15f78b..1b50eb642b 100644
--- a/src/cmd/compile/internal/ssa/lower.go
+++ b/src/cmd/compile/internal/ssa/lower.go
@@ -21,7 +21,7 @@ func checkLower(f *Func) {
continue // lowered
}
switch v.Op {
- case OpSP, OpSB, OpInitMem, OpArg, OpCopy, OpPhi, OpVarDef, OpVarKill:
+ case OpSP, OpSB, OpInitMem, OpArg, OpPhi, OpVarDef, OpVarKill:
continue // ok not to lower
}
s := "not lowered: " + v.Op.String() + " " + v.Type.SimpleString()