Don't create instructions from ConstantExpr's in CFLAliasAnalysis.
authorPete Cooper <peter_cooper@apple.com>
Fri, 12 Jun 2015 16:13:54 +0000 (16:13 +0000)
committerPete Cooper <peter_cooper@apple.com>
Fri, 12 Jun 2015 16:13:54 +0000 (16:13 +0000)
commit0433a64174679335d076783544f2a678b41e160d
tree3204d8b32be7d4825e06b09416974fc0b9cdad85
parentcb2dfa64784ea6cc10b2df7a4827c15de5ac987d
Don't create instructions from ConstantExpr's in CFLAliasAnalysis.

The CFLAA code currently calls ConstantExpr::getAsInstruction which creates an instruction from a constant expr.

We then pass that instruction to the InstVisitor to analyze it.

Its not necessary to create these instructions as we can just cast from Constant to Operator in the visitor.  This is how other InstVisitor’s such as SelectionDAGBuilder handle ConstantExpr.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239616 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Analysis/CFLAliasAnalysis.cpp