aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGDecl.cpp
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2011-02-09 00:37:30 +0000
committerDevang Patel <dpatel@apple.com>2011-02-09 00:37:30 +0000
commit570729e71654f0564bf2ce6504f8629a96850914 (patch)
tree2412850fabc4f3648cdec3bcb5b56cf123fde355 /lib/CodeGen/CGDecl.cpp
parent2bbbfb2cc36f7e5ee86b7fd22ec040be36d7c9d0 (diff)
If an aggregate argument is passed indirectly because it has non trivial
destructor or copy constructor than let debug info know about it. Radar 8945514. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125142 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDecl.cpp')
-rw-r--r--lib/CodeGen/CGDecl.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/CodeGen/CGDecl.cpp b/lib/CodeGen/CGDecl.cpp
index c3708d1efd..44568bc2aa 100644
--- a/lib/CodeGen/CGDecl.cpp
+++ b/lib/CodeGen/CGDecl.cpp
@@ -927,7 +927,8 @@ void CodeGenFunction::EmitAutoVarDecl(const VarDecl &D,
/// Emit an alloca (or GlobalValue depending on target)
/// for the specified parameter and set up LocalDeclMap.
-void CodeGenFunction::EmitParmDecl(const VarDecl &D, llvm::Value *Arg) {
+void CodeGenFunction::EmitParmDecl(const VarDecl &D, llvm::Value *Arg,
+ bool IndirectArg) {
// FIXME: Why isn't ImplicitParamDecl a ParmVarDecl?
assert((isa<ParmVarDecl>(D) || isa<ImplicitParamDecl>(D)) &&
"Invalid argument to EmitParmDecl");
@@ -956,6 +957,6 @@ void CodeGenFunction::EmitParmDecl(const VarDecl &D, llvm::Value *Arg) {
// Emit debug info for param declaration.
if (CGDebugInfo *DI = getDebugInfo()) {
DI->setLocation(D.getLocation());
- DI->EmitDeclareOfArgVariable(&D, DeclPtr, Builder);
+ DI->EmitDeclareOfArgVariable(&D, DeclPtr, Builder, IndirectArg);
}
}