daniel prefers completed thoughts.

llvm-svn: 59404
This commit is contained in:
Chris Lattner 2008-11-16 06:16:27 +00:00
parent 44152742a0
commit 9ce8a533cd
1 changed files with 1 additions and 1 deletions

View File

@ -1163,7 +1163,7 @@ VisitConditionalOperator(const ConditionalOperator *E) {
// If this is a really simple expression (like x ? 4 : 5), emit this as a
// select instead of as control flow. We can only do this if it is cheap and
// safe to
// safe to evaluate the LHS and RHS unconditionally.
if (E->getLHS() && isCheapEnoughToEvaluateUnconditionally(E->getLHS()) &&
isCheapEnoughToEvaluateUnconditionally(E->getRHS())) {
llvm::Value *CondV = CGF.EvaluateExprAsBool(E->getCond());