OSDN Git Service

[IndVars] Assert that the incoming IR is in LCSSA
authorSanjoy Das <sanjoy@playingwithpointers.com>
Mon, 30 May 2016 01:37:39 +0000 (01:37 +0000)
committerSanjoy Das <sanjoy@playingwithpointers.com>
Mon, 30 May 2016 01:37:39 +0000 (01:37 +0000)
commit285ed3c6e483173a988518ec6f1d5878ee01b14a
treefb285c0d5bab907ded9aa82d9db524e6123165b0
parent9aaeb83f58ccc51e3eaf63ae058ec83c16da9256
[IndVars] Assert that the incoming IR is in LCSSA

Since we already assert that the outgoing IR is in LCSSA, it is easy to
get misled into thinking that -indvars broke LCSSA if the incoming IR is
non-LCSSA.  Checking this pre-condition will make such cases break in
more obvious ways.

Inspired by (but does _not_ fix) PR26682.

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