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:
ef3baf0
)
Branch conditions must be i1
author
Chris Lattner
<sabre@nondot.org>
Fri, 12 Jan 2007 18:30:11 +0000
(18:30 +0000)
committer
Chris Lattner
<sabre@nondot.org>
Fri, 12 Jan 2007 18:30:11 +0000
(18:30 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33129
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Transforms/IPO/GlobalOpt.cpp
patch
|
blob
|
history
diff --git
a/lib/Transforms/IPO/GlobalOpt.cpp
b/lib/Transforms/IPO/GlobalOpt.cpp
index 86657c2c0e51c0e8e9f1cf0992263ee3e869aec2..bbf5241b34f975612bc16c86322deff01a19c042 100644
(file)
--- a/
lib/Transforms/IPO/GlobalOpt.cpp
+++ b/
lib/Transforms/IPO/GlobalOpt.cpp
@@
-1799,10
+1799,8
@@
static bool EvaluateFunction(Function *F, Constant *&RetVal,
} else {
ConstantInt *Cond =
dyn_cast<ConstantInt>(getVal(Values, BI->getCondition()));
+ if (!Cond) return false; // Cannot determine.
- // Cannot determine.
- if (!Cond || Cond->getType() != Type::Int1Ty)
- return false;
NewBB = BI->getSuccessor(!Cond->getZExtValue());
}
} else if (SwitchInst *SI = dyn_cast<SwitchInst>(CurInst)) {