diff options
| author | David Blaikie <dblaikie@gmail.com> | 2014-04-26 22:12:18 +0000 |
|---|---|---|
| committer | David Blaikie <dblaikie@gmail.com> | 2014-04-26 22:12:18 +0000 |
| commit | 2b4669de8a893e2c62b808c509f2f3e74057f29a (patch) | |
| tree | f076a9b24c726119c7a15e3fc9fa9ffe79269f6a | |
| parent | 357b36a2c00c3337fb7011dc3f91e072f0ab81ea (diff) | |
| download | bcm5719-llvm-2b4669de8a893e2c62b808c509f2f3e74057f29a.tar.gz bcm5719-llvm-2b4669de8a893e2c62b808c509f2f3e74057f29a.zip | |
DebugInfo: Fix and test a regression caused by r207263 causing the DW_AT_object_pointer to go missing on blocks
Noticed by inspection. Test coverage added.
llvm-svn: 207333
| -rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp | 2 | ||||
| -rw-r--r-- | llvm/test/DebugInfo/X86/debug-info-blocks.ll | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp index 0465b8929a7..69f7d1146d9 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp @@ -538,9 +538,9 @@ DIE *DwarfDebug::createScopeChildrenDIE( std::unique_ptr<DIE> Variable = TheCU.constructVariableDIE(*DV, Scope->isAbstractScope()); assert(Variable); - Children.push_back(std::move(Variable)); if (DV->isObjectPointer()) ObjectPointer = Variable.get(); + Children.push_back(std::move(Variable)); } for (LexicalScope *LS : Scope->getChildren()) if (DIE *Nested = constructScopeDIE(TheCU, LS)) diff --git a/llvm/test/DebugInfo/X86/debug-info-blocks.ll b/llvm/test/DebugInfo/X86/debug-info-blocks.ll index 9daeceeb779..b2531f64708 100644 --- a/llvm/test/DebugInfo/X86/debug-info-blocks.ll +++ b/llvm/test/DebugInfo/X86/debug-info-blocks.ll @@ -7,6 +7,7 @@ ; CHECK: DW_TAG_subprogram ; CHECK: DW_AT_name{{.*}}_block_invoke +; CHECK: DW_AT_object_pointer ; CHECK-NOT: DW_TAG_subprogram ; CHECK: DW_TAG_formal_parameter |

