summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGDecl.cpp
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2011-03-01 22:59:40 +0000
committerDevang Patel <dpatel@apple.com>2011-03-01 22:59:40 +0000
commit3bc2dedb403f23e38f4ab765fe2b78bd101f041d (patch)
tree8aa56b3ad3bf83216aa5a4dbed812d2ab44555fc /clang/lib/CodeGen/CGDecl.cpp
parent6c622ef1bcda9f544cbc64de6cce12cbf7dd08b2 (diff)
downloadbcm5719-llvm-3bc2dedb403f23e38f4ab765fe2b78bd101f041d.tar.gz
bcm5719-llvm-3bc2dedb403f23e38f4ab765fe2b78bd101f041d.zip
Encode argument numbering in debug info so that code generator can emit them in order.
This fixes few blocks.exp regressions. llvm-svn: 126795
Diffstat (limited to 'clang/lib/CodeGen/CGDecl.cpp')
-rw-r--r--clang/lib/CodeGen/CGDecl.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGDecl.cpp b/clang/lib/CodeGen/CGDecl.cpp
index f4db01d2570..ecc0a4c2d56 100644
--- a/clang/lib/CodeGen/CGDecl.cpp
+++ b/clang/lib/CodeGen/CGDecl.cpp
@@ -1000,7 +1000,8 @@ void CodeGenFunction::EmitAutoVarCleanups(const AutoVarEmission &emission) {
/// 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,
+ unsigned ArgNo) {
// FIXME: Why isn't ImplicitParamDecl a ParmVarDecl?
assert((isa<ParmVarDecl>(D) || isa<ImplicitParamDecl>(D)) &&
"Invalid argument to EmitParmDecl");
@@ -1046,6 +1047,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, ArgNo, Builder);
}
}
OpenPOWER on IntegriCloud