summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorVedant Kumar <vsk@apple.com>2019-12-20 15:12:18 -0800
committerVedant Kumar <vsk@apple.com>2019-12-20 15:26:31 -0800
commitfa4701e1979553c2df61698ac1ac212627630442 (patch)
tree777487573f25b50c5b1050cc5a0cd6e17eaa2224 /llvm/lib/CodeGen
parent79daafc90308787b52a5d3a7586e82acd5e374b3 (diff)
downloadbcm5719-llvm-fa4701e1979553c2df61698ac1ac212627630442.tar.gz
bcm5719-llvm-fa4701e1979553c2df61698ac1ac212627630442.zip
[DWARF] Defer creating declaration DIEs until we prepare call site info
It isn't necessary to create DIEs for all of the declaration subprograms in a CU's retainedTypes list. We can defer creating these subprograms until we need to prepare a call site tag that refers to one. This cleanup was mentioned in passing in D70350.
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp7
1 files changed, 0 insertions, 7 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
index d1a36299dc4..624e1a513ec 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
@@ -924,13 +924,6 @@ DwarfDebug::getOrCreateDwarfCompileUnit(const DICompileUnit *DIUnit) {
NewCU.setSection(Asm->getObjFileLowering().getDwarfInfoSection());
}
- // Create DIEs for function declarations used for call site debug info.
- // Note: Declaration subprograms imported by LTO are not added to the unit's
- // list of retained types, so their DIEs are not constructed here.
- for (auto Scope : DIUnit->getRetainedTypes())
- if (auto *SP = dyn_cast_or_null<DISubprogram>(Scope))
- NewCU.getOrCreateSubprogramDIE(SP);
-
CUMap.insert({DIUnit, &NewCU});
CUDieMap.insert({&NewCU.getUnitDie(), &NewCU});
return NewCU;
OpenPOWER on IntegriCloud