diff options
author | Eric Christopher <echristo@apple.com> | 2012-03-14 02:59:17 +0000 |
---|---|---|
committer | Eric Christopher <echristo@apple.com> | 2012-03-14 02:59:17 +0000 |
commit | a9916d0296fc74bb40aa2e02a1f42bdf4b4239a4 (patch) | |
tree | 46cf4f61acc414306387de8b48120c00103601e5 /llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp | |
parent | 29e08cbb9c1408d9b8af8b7fa504656211e4a8ae (diff) | |
download | bcm5719-llvm-a9916d0296fc74bb40aa2e02a1f42bdf4b4239a4.tar.gz bcm5719-llvm-a9916d0296fc74bb40aa2e02a1f42bdf4b4239a4.zip |
Remove the DW_AT_MIPS_linkage name attribute when we don't need it
output (we're emitting a specification already and the information
isn't changing).
Saves 1% on the debug information for a build of llvm.
Fixes rdar://11043421
llvm-svn: 152697
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp')
-rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp index af99f6ba4da..63194948f4d 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp @@ -1007,11 +1007,6 @@ DIE *CompileUnit::getOrCreateSubprogramDIE(DISubprogram SP) { // Add function template parameters. addTemplateParams(*SPDie, SP.getTemplateParams()); - StringRef LinkageName = SP.getLinkageName(); - if (!LinkageName.empty()) - addString(SPDie, dwarf::DW_AT_MIPS_linkage_name, - getRealLinkageName(LinkageName)); - // If this DIE is going to refer declaration info using AT_specification // then there is no need to add other attributes. if (DeclDie) { @@ -1022,6 +1017,11 @@ DIE *CompileUnit::getOrCreateSubprogramDIE(DISubprogram SP) { return SPDie; } + StringRef LinkageName = SP.getLinkageName(); + if (!LinkageName.empty()) + addString(SPDie, dwarf::DW_AT_MIPS_linkage_name, + getRealLinkageName(LinkageName)); + // Constructors and operators for anonymous aggregates do not have names. if (!SP.getName().empty()) addString(SPDie, dwarf::DW_AT_name, SP.getName()); |