projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
12fe2b1
)
Do not clone arbitrary condition instructions.
author
Chris Lattner
<sabre@nondot.org>
Sun, 2 May 2004 05:19:36 +0000
(
05:19
+0000)
committer
Chris Lattner
<sabre@nondot.org>
Sun, 2 May 2004 05:19:36 +0000
(
05:19
+0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13316
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Transforms/Utils/SimplifyCFG.cpp
patch
|
blob
|
history
diff --git
a/lib/Transforms/Utils/SimplifyCFG.cpp
b/lib/Transforms/Utils/SimplifyCFG.cpp
index a5153d65e3208af998c856b1c39f93e2b1fa99b1..446bad88f7514ebb0b7e0f1696949fd255431e03 100644
(file)
--- a/
lib/Transforms/Utils/SimplifyCFG.cpp
+++ b/
lib/Transforms/Utils/SimplifyCFG.cpp
@@
-806,7
+806,7
@@
bool llvm::SimplifyCFG(BasicBlock *BB) {
// predecessor and use logical operations to pick the right destination.
BasicBlock *TrueDest = BI->getSuccessor(0);
BasicBlock *FalseDest = BI->getSuccessor(1);
- if (
Instruction *Cond = dyn_cast<Instruction
>(BI->getCondition()))
+ if (
BinaryOperator *Cond = dyn_cast<BinaryOperator
>(BI->getCondition()))
if (Cond->getParent() == BB && &BB->front() == Cond &&
Cond->getNext() == BI && Cond->hasOneUse() &&
TrueDest != BB && FalseDest != BB)