[PATCH] D74843: [llvm-objdump] Add entry_value locations to variable display

Adrian Prantl via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 27 08:39:24 PST 2020


aprantl added inline comments.


================
Comment at: llvm/test/tools/llvm-objdump/ARM/debug-vars-entry-value.s:1
+# RUN: llvm-mc --triple armv8a--none-eabi < %s --filetype=obj | \
+# RUN:     llvm-objdump - -d --debug-vars --no-show-raw-insn | \
----------------
jhenderson wrote:
> aprantl wrote:
> > It would be a lot more efficient to test this in `unittests/DebugInfo/dwarf`, but just dumping the expression bytes themselves. Otherwise the canonical place to test dwarf dumping facilities is usually llvm-dwarfdump.
> > 
> > I'm kind of worried that this test will need to be updated every time someone tunes the output formatting of objdump
> +1 to this. The `prettyPrint` function looks ripe for gtest unit testing. I wouldn't necessarily worry about covering every code path in the first instance, but you could work towards it that way.
I think this test should be deleted now, it doesn't add anything over the unit test, right?


================
Comment at: llvm/unittests/DebugInfo/DWARF/DWARFExpressionCompactPrinterTest.cpp:105
+  TestExprPrinter({DW_OP_entry_value, 0x01, DW_OP_reg0, DW_OP_stack_value},
+                  "entry(R0)");
+}
----------------
Nice.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D74843





More information about the llvm-commits mailing list