diff options
author | Chris Lattner <sabre@nondot.org> | 2009-11-12 01:41:34 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-11-12 01:41:34 +0000 |
commit | 87e9f59c7a823ba86d8aafa4e15ac03e6db244c3 (patch) | |
tree | e83afecfd662d89dd8a570f1954de4aab4b6a6b5 /lib/Transforms | |
parent | 1c96b4187be7589492dccf33e9fe7679ac61023d (diff) |
with the new code we can thread non-instruction values. This
allows us to handle the test10 testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86924 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms')
-rw-r--r-- | lib/Transforms/Scalar/JumpThreading.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/Transforms/Scalar/JumpThreading.cpp b/lib/Transforms/Scalar/JumpThreading.cpp index e7ca0f4b50..47bebf90d3 100644 --- a/lib/Transforms/Scalar/JumpThreading.cpp +++ b/lib/Transforms/Scalar/JumpThreading.cpp @@ -518,8 +518,13 @@ bool JumpThreading::ProcessBlock(BasicBlock *BB) { } // All the rest of our checks depend on the condition being an instruction. - if (CondInst == 0) + if (CondInst == 0) { + // FIXME: Unify this with code below. + if (LVI && ProcessThreadableEdges(Condition, BB)) + return true; return false; + } + // See if this is a phi node in the current block. if (PHINode *PN = dyn_cast<PHINode>(CondInst)) |