[Lldb-commits] [PATCH] D62570: [WIP] Use LLVM's debug line parser in LLDB

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu May 30 06:30:36 PDT 2019


labath added a comment.

BTW, how good is the llvm debug_line parser when it comes to handling invalid input? Looking through the asserts in the file, it looks like at least two of them can be tripped by feeding it bad data:

- I'm pretty sure the DW_LNCT_*** handling code can blow up if the data forms are not of the expected class, or if DW_LNCT_MD5 points to data of incorrect size https://github.com/llvm-mirror/llvm/blob/0d9a164240ed293701eea6af0ea338caf227c338/lib/DebugInfo/DWARF/DWARFDebugLine.cpp#L254
- possibly the header parsing code can assert if the header contains invalid address size (I'd have to check how exactly is the address size on the data extractor being set to be sure) https://github.com/llvm-mirror/llvm/blob/0d9a164240ed293701eea6af0ea338caf227c338/lib/DebugInfo/DWARF/DWARFDebugLine.cpp#L302


Repository:
  rLLDB LLDB

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D62570/new/

https://reviews.llvm.org/D62570





More information about the lldb-commits mailing list