From becd8e75b80bf84b99dbfd650930024dd743ddef Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Mon, 28 Apr 2014 20:27:02 +0000 Subject: DwarfDebug: Omit DW_AT_object_pointer on inlined_subroutines While refactoring out constructScopeDIE into two functions I realized we were emitting DW_AT_object_pointer in the inlined subroutine when we didn't need to (GCC doesn't, and the abstract subprogram definition has the information already). So here's the refactoring and the bug fix. This is one step of refactoring to remove some subtle memory ownership semantics. It turns out the original constructScopeDIE returned ownership in its return value in some cases and not in others. The split into two functions now separates those two semantics - further cleanup (unique_ptr, etc) will follow. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207441 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/AsmPrinter/DwarfDebug.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/CodeGen/AsmPrinter/DwarfDebug.h') diff --git a/lib/CodeGen/AsmPrinter/DwarfDebug.h b/lib/CodeGen/AsmPrinter/DwarfDebug.h index 1c4903c948..e9c656e5da 100644 --- a/lib/CodeGen/AsmPrinter/DwarfDebug.h +++ b/lib/CodeGen/AsmPrinter/DwarfDebug.h @@ -367,6 +367,8 @@ class DwarfDebug : public AsmPrinterHandler { /// \brief Construct a DIE for this scope. DIE *constructScopeDIE(DwarfCompileUnit &TheCU, LexicalScope *Scope); + /// \brief Construct a DIE for this scope. + DIE *constructSubprogramScopeDIE(DwarfCompileUnit &TheCU, LexicalScope *Scope); /// A helper function to create children of a Scope DIE. DIE *createScopeChildrenDIE(DwarfCompileUnit &TheCU, LexicalScope *Scope, SmallVectorImpl> &Children); -- cgit v1.2.3