indvars cruft: don't replace phi nodes for no reason.
authorAndrew Trick <atrick@apple.com>
Mon, 18 May 2015 16:49:34 +0000 (16:49 +0000)
committerAndrew Trick <atrick@apple.com>
Mon, 18 May 2015 16:49:34 +0000 (16:49 +0000)
commit0b9ee775f5e2c8c2cc344357795328371b7c1d05
tree77a21a63912ab9172307b04c214a126e0a7ce204
parent688ae334a384718bbd7227881a5ff1dee3baf8d1
indvars cruft: don't replace phi nodes for no reason.

Don't replace a phi with an identical phi. This was done long ago to
"preserve" IVUsers analysis. The code has already called
SE->forgetValue(PN) so I see no purpose in creating a new value for
the phi.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@237587 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/IndVarSimplify.cpp