diff options
author | David Blaikie <dblaikie@gmail.com> | 2014-03-18 01:17:26 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2014-03-18 01:17:26 +0000 |
commit | 4a2f95f60ee386dc87d29d5f763fa4fb046550ff (patch) | |
tree | 4dc2f624e58e405c9fb6e133613d6d1ee8000a27 /llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h | |
parent | cf9e671f5c909334ae5f6e0402e33162282c82fd (diff) | |
download | bcm5719-llvm-4a2f95f60ee386dc87d29d5f763fa4fb046550ff.tar.gz bcm5719-llvm-4a2f95f60ee386dc87d29d5f763fa4fb046550ff.zip |
DebugInfo: Implement debug_line.dwo for file names used in type units during -gsplit-dwarf
This removes an attribute (and more importantly, a relocation) from
skeleton type units and removes some unnecessary file names from the
debug_line section that remains in the .o (and linked executable) file.
There's still a few places we could shave off some more space here:
* use compilation dir of the underlying compilation unit (since all the
type units share that compilation dir - though this would be more
complicated in LTO cases where they don't (keep a map of compilation
dir->line table header?))
* Remove some of the unnecessary header fields from the line table since
they're not needed in this situation (about 12 bytes per table).
llvm-svn: 204099
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h')
-rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h index 71ff75d640a..4756509d094 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h @@ -27,6 +27,7 @@ #include "llvm/IR/DebugInfo.h" #include "llvm/IR/DebugLoc.h" #include "llvm/MC/MachineLocation.h" +#include "llvm/MC/MCDwarf.h" #include "llvm/Support/Allocator.h" namespace llvm { @@ -486,6 +487,10 @@ class DwarfDebug : public AsmPrinterHandler { // Holder for the skeleton information. DwarfFile SkeletonHolder; + // Store file names for type units under fission in a line table header that + // will be emitted into debug_line.dwo. + MCDwarfLineTableHeader SplitTypeUnitFileTable; + void addScopeVariable(LexicalScope *LS, DbgVariable *Var); const SmallVectorImpl<DwarfUnit *> &getUnits() { @@ -621,6 +626,9 @@ class DwarfDebug : public AsmPrinterHandler { /// \brief Emit the debug abbrev dwo section. void emitDebugAbbrevDWO(); + /// \brief Emit the debug line dwo section. + void emitDebugLineDWO(); + /// \brief Emit the debug str dwo section. void emitDebugStrDWO(); |