[PATCH] D75043: [DWARFDebugLine] Avoid dumping prologue members we did not parse

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 25 00:52:03 PST 2020


jhenderson added a comment.

Looks good in principle, just a couple of test suggestions from me.



================
Comment at: llvm/test/tools/llvm-dwarfdump/X86/debug_line_invalid.test:44
 # FATAL:      debug_line[0x00000048]
-# FATAL-NEXT: Line table prologue
-# FATAL-NEXT: total_length: 0xfffffffe
+# RESERVED: warning: parsing line table prologue at offset 0x00000048 unsupported reserved unit length found of value 0xfffffffe
 # FATAL-NOT:  debug_line
----------------
For this and the two version checks, it's probably worth adding a CHECK-NOT immediately after the warning that shows the (rest of the) prologue is not printed.

Without it, I don't think you have any test coverage for the early exit, right?


================
Comment at: llvm/test/tools/llvm-dwarfdump/X86/debug_line_invalid.test:61
+# ALL-NEXT: warning: failed to parse entry content descriptions because no path was found
 # NONFATAL-NEXT: Line table prologue
 # NONFATAL-NOT:  include_directories
----------------
For each of these other checks, it might be worth an extra CHECK line that shows that we do continue to print after the version field. What do you think? (Obviously, it's not necessary where there is already a file/include directory table check).


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D75043





More information about the llvm-commits mailing list