SCEVExpander: Don't crash when trying to merge two constant phis.
authorBenjamin Kramer <benny.kra@googlemail.com>
Fri, 19 Oct 2012 16:37:30 +0000 (16:37 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Fri, 19 Oct 2012 16:37:30 +0000 (16:37 +0000)
commita225ed8d2b661a5ceb6f108930b3f889501d929f
tree306f1ea72fc85f69106cf33df3fadaa1a32186e8
parent2afd661685aea4ce232ab67554f0aa3110317619
SCEVExpander: Don't crash when trying to merge two constant phis.

Just constant fold them so they can't cause any trouble. Fixes PR12627.

llvm-svn: 166286
llvm/lib/Analysis/ScalarEvolutionExpander.cpp
llvm/test/Transforms/IndVarSimplify/2012-10-19-congruent-constant.ll [new file with mode: 0644]
llvm/test/Transforms/IndVarSimplify/no-iv-rewrite.ll