summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGExprComplex.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2008-11-11 09:41:28 +0000
committerDaniel Dunbar <daniel@zuster.org>2008-11-11 09:41:28 +0000
commitc56e67644f705e0728b802447d82902db2305c75 (patch)
treee7f314727a0895560c281fe217096f1074f94585 /clang/lib/CodeGen/CGExprComplex.cpp
parenta0821bf8a2a386d24dbe3a51b3fdd74304b3104f (diff)
downloadbcm5719-llvm-c56e67644f705e0728b802447d82902db2305c75.tar.gz
bcm5719-llvm-c56e67644f705e0728b802447d82902db2305c75.zip
Add CodeGenFunction::EmitBranch.
- Emits an unconditional branch, with extra logic to avoid generating spurious branches out of dummy blocks. llvm-svn: 59037
Diffstat (limited to 'clang/lib/CodeGen/CGExprComplex.cpp')
-rw-r--r--clang/lib/CodeGen/CGExprComplex.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGExprComplex.cpp b/clang/lib/CodeGen/CGExprComplex.cpp
index d12d355ee70..92226620269 100644
--- a/clang/lib/CodeGen/CGExprComplex.cpp
+++ b/clang/lib/CodeGen/CGExprComplex.cpp
@@ -479,14 +479,14 @@ VisitConditionalOperator(const ConditionalOperator *E) {
assert(E->getLHS() && "Must have LHS for complex value");
ComplexPairTy LHS = Visit(E->getLHS());
- Builder.CreateBr(ContBlock);
LHSBlock = Builder.GetInsertBlock();
+ CGF.EmitBranch(ContBlock);
CGF.EmitBlock(RHSBlock);
ComplexPairTy RHS = Visit(E->getRHS());
- Builder.CreateBr(ContBlock);
RHSBlock = Builder.GetInsertBlock();
+ CGF.EmitBranch(ContBlock);
CGF.EmitBlock(ContBlock);
OpenPOWER on IntegriCloud