[PATCH] [dwarfdump] Resolve also variable specifications/abstract_origins.

Frederic Riss friss at apple.com
Mon Oct 6 08:30:44 PDT 2014


Hi dblaikie, samsonov,

DW_AT_specification and DW_AT_abstract_origin resolving was only performed
on subroutine DIEs because it used the getSubroutineName method. Introduce
a more generic getName() and use it to dump the reference attributes.

Testcases have been updated to check the printed names instead of the offsets
except when the name could be ambiguous.

I implemented getName in a way that allowed to replicate exactly the current
getSubroutineName behavior (checking that each DIE in the reference chain is
a subroutine DIE). It could be made a bit simpler if getSubroutineName
only checked that the root DIE is a subroutine DIE and then called a generic
getName() afterwards.

I can of course commit this in 2 patches, 1 for the getName addition and another
for the use in dump().

http://reviews.llvm.org/D5625

Files:
  lib/DebugInfo/DWARFDebugInfoEntry.cpp
  lib/DebugInfo/DWARFDebugInfoEntry.h
  test/DebugInfo/PR20038.ll
  test/DebugInfo/X86/concrete_out_of_line.ll
  test/DebugInfo/X86/dbg-value-inlined-parameter.ll
  test/DebugInfo/X86/debug-info-static-member.ll
  test/DebugInfo/X86/gnu-public-names.ll
  test/DebugInfo/cross-cu-inlining.ll
  test/DebugInfo/missing-abstract-variable.ll
  test/DebugInfo/namespace_inline_function_definition.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D5625.14454.patch
Type: text/x-patch
Size: 17047 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141006/b7fa9958/attachment.bin>


More information about the llvm-commits mailing list