diff options
author | Adrian Prantl <aprantl@apple.com> | 2015-02-03 18:40:42 +0000 |
---|---|---|
committer | Adrian Prantl <aprantl@apple.com> | 2015-02-03 18:40:42 +0000 |
commit | 39428e74a04d93a6732a850c215f359a122cfff1 (patch) | |
tree | 237da63566e87603c682e084a7c6c56feb48c730 /clang/lib/CodeGen/CGStmtOpenMP.cpp | |
parent | 6693d0839af5ae38d7a09bfada7af7a24611d884 (diff) | |
download | bcm5719-llvm-39428e74a04d93a6732a850c215f359a122cfff1.tar.gz bcm5719-llvm-39428e74a04d93a6732a850c215f359a122cfff1.zip |
Merge ArtificialLocation into ApplyDebugLocation and make a clear
distinction between the different use-cases. With the previous default
behavior we would occasionally emit empty debug locations in situations
where they actually were strictly required (= on invoke insns).
We now have a choice between defaulting to an empty location or an
artificial location.
Specifically, this fixes a bug caused by a missing debug location when
emitting C++ EH cleanup blocks from within an artificial function, such as
an ObjC destroy helper function.
rdar://problem/19670595
llvm-svn: 228003
Diffstat (limited to 'clang/lib/CodeGen/CGStmtOpenMP.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGStmtOpenMP.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGStmtOpenMP.cpp b/clang/lib/CodeGen/CGStmtOpenMP.cpp index 60958d071c5..395f6fa69ac 100644 --- a/clang/lib/CodeGen/CGStmtOpenMP.cpp +++ b/clang/lib/CodeGen/CGStmtOpenMP.cpp @@ -86,13 +86,13 @@ static void EmitOMPIfClause(CodeGenFunction &CGF, const Expr *Cond, // Emit the 'else' code if present. { // There is no need to emit line number for unconditional branch. - ApplyDebugLocation DL(CGF); + ApplyDebugLocation NL(CGF, ApplyDebugLocation::NoLocation); CGF.EmitBlock(ElseBlock); } CodeGen(/*ThenBlock*/ false); { // There is no need to emit line number for unconditional branch. - ApplyDebugLocation DL(CGF); + ApplyDebugLocation NL(CGF, ApplyDebugLocation::NoLocation); CGF.EmitBranch(ContBlock); } // Emit the continuation block for code after the if. |