DebugInfo: Make pubnames header printing similar to unit header printing
authorDavid Blaikie <dblaikie@gmail.com>
Fri, 1 Nov 2013 17:53:30 +0000 (17:53 +0000)
committerDavid Blaikie <dblaikie@gmail.com>
Fri, 1 Nov 2013 17:53:30 +0000 (17:53 +0000)
commit2e110c3fa62bce0182c1635964f5e09e34e3cbb5
tree5c87038de5083a5105934556656693bf35761326
parent26cc826a0e4693b861776d6b349d41d0e5c2678e
DebugInfo: Make pubnames header printing similar to unit header printing

In a failed attempt to allow the gnu-public-names.ll test case to not
hardcode the size of the unit that the pubnames section referred to I've
at least managed to have unit headers and pubnames headers print out in
a similar style.

This failed to achieve the desired goal because the header in a unit
specifies the length of the unit without the length element of the
header whereas the length in the pubnames includes this element, so the
numbers are off by 4 bytes. I don't know of any arithmetic powers in
FileCheck so the test case can't simply say "CU_LENGTH + 4".

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193872 91177308-0d34-0410-b5e6-96231b3b80d8
lib/DebugInfo/DWARFContext.cpp
test/DebugInfo/X86/gnu-public-names.ll
test/DebugInfo/dwarf-public-names.ll
test/DebugInfo/dwarfdump-pubnames.test