Add line table verification to lldb-dwarfdump --verify
authorGreg Clayton <gclayton@apple.com>
Tue, 2 May 2017 22:48:52 +0000 (22:48 +0000)
committerGreg Clayton <gclayton@apple.com>
Tue, 2 May 2017 22:48:52 +0000 (22:48 +0000)
commit6707046f9018c34274cdfbc317eb6041631e7f2c
tree283c5e2bd355b0b9b2a6d6e58b9918457f16f186
parent4a01ffbd6aca4a26f4a7b6f9112e920a56ff6e07
Add line table verification to lldb-dwarfdump --verify

This patch verifies the .debug_line:
- verify all addresses in a line table sequence have ascending addresses
- verify that all line table file indexes are valid

Unit tests added for both cases.

Differential Revision: https://reviews.llvm.org/D32765

llvm-svn: 301984
llvm/include/llvm/DebugInfo/DWARF/DWARFDebugLine.h
llvm/lib/DebugInfo/DWARF/DWARFContext.cpp
llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp
llvm/unittests/DebugInfo/DWARF/DWARFDebugInfoTest.cpp