summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2014-03-12 03:34:38 +0000
committerDavid Blaikie <dblaikie@gmail.com>2014-03-12 03:34:38 +0000
commitadbea1ef9f56712dc050bd68d8026de643913826 (patch)
tree88d32fb4d24639e8a3942e44e7a3dcd89f45e58c /llvm/lib/CodeGen
parentbfaec9bf8b8ce377324026486cd3e8f21bc4c1da (diff)
downloadbcm5719-llvm-adbea1ef9f56712dc050bd68d8026de643913826.tar.gz
bcm5719-llvm-adbea1ef9f56712dc050bd68d8026de643913826.zip
DebugInfo: Omit pubnames/pubtypes when compiling with -gmlt
llvm-svn: 203634
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
index e046bf417b6..fe5ded34cbe 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
@@ -998,8 +998,9 @@ void DwarfUnit::updateAcceleratorTables(DIScope Context, DIType Ty,
unsigned Flags = IsImplementation ? dwarf::DW_FLAG_type_implementation : 0;
addAccelType(Ty.getName(), std::make_pair(TyDIE, Flags));
- if (!Context || Context.isCompileUnit() || Context.isFile() ||
- Context.isNameSpace())
+ if ((!Context || Context.isCompileUnit() || Context.isFile() ||
+ Context.isNameSpace()) &&
+ getCUNode().getEmissionKind() != DIBuilder::LineTablesOnly)
GlobalTypes[getParentContextString(Context) + Ty.getName().str()] = TyDIE;
}
}
@@ -1064,6 +1065,8 @@ void DwarfUnit::addAccelType(StringRef Name,
/// addGlobalName - Add a new global name to the compile unit.
void DwarfUnit::addGlobalName(StringRef Name, DIE *Die, DIScope Context) {
+ if (getCUNode().getEmissionKind() == DIBuilder::LineTablesOnly)
+ return;
std::string FullName = getParentContextString(Context) + Name.str();
GlobalNames[FullName] = Die;
}
OpenPOWER on IntegriCloud