summaryrefslogtreecommitdiff
path: root/lib/Transforms/Utils/LowerInvoke.cpp
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2010-10-18 18:53:44 +0000
committerDevang Patel <dpatel@apple.com>2010-10-18 18:53:44 +0000
commit3bcb3a6b8d95a19a3b4d61e7a59c38ac2fd392c1 (patch)
tree060b36603583245f6cd8d80cddaf993adc490bc9 /lib/Transforms/Utils/LowerInvoke.cpp
parent4021fccf9fdb60906e5f16c98e72042240867495 (diff)
downloadllvm-3bcb3a6b8d95a19a3b4d61e7a59c38ac2fd392c1.tar.gz
llvm-3bcb3a6b8d95a19a3b4d61e7a59c38ac2fd392c1.tar.bz2
llvm-3bcb3a6b8d95a19a3b4d61e7a59c38ac2fd392c1.tar.xz
Transfer debug loc to lowered call.
Patch by Alexander Herz! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116733 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils/LowerInvoke.cpp')
-rw-r--r--lib/Transforms/Utils/LowerInvoke.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Transforms/Utils/LowerInvoke.cpp b/lib/Transforms/Utils/LowerInvoke.cpp
index e8a11e3d0c..77d7f153d7 100644
--- a/lib/Transforms/Utils/LowerInvoke.cpp
+++ b/lib/Transforms/Utils/LowerInvoke.cpp
@@ -187,6 +187,7 @@ bool LowerInvoke::insertCheapEHSupport(Function &F) {
NewCall->takeName(II);
NewCall->setCallingConv(II->getCallingConv());
NewCall->setAttributes(II->getAttributes());
+ NewCall->setDebugLoc(II->getDebugLoc());
II->replaceAllUsesWith(NewCall);
// Insert an unconditional branch to the normal destination.
@@ -267,6 +268,7 @@ void LowerInvoke::rewriteExpensiveInvoke(InvokeInst *II, unsigned InvokeNo,
NewCall->takeName(II);
NewCall->setCallingConv(II->getCallingConv());
NewCall->setAttributes(II->getAttributes());
+ NewCall->setDebugLoc(II->getDebugLoc());
II->replaceAllUsesWith(NewCall);
// Replace the invoke with an uncond branch.