[PATCH] D105687: [Debug-Info] [llvm-dwarfdump] Don't use DW_FORM_data4/8 to encode the constants for DW_AT_data_member_location.

Paul Robinson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 21 07:57:50 PDT 2021


probinson added a comment.

Sorry for the slow response, I will try to be better about it.

With the test case being an asm file, what it is actually testing is how llvm-dwarfdump displays the DWARF that is explicitly given in the .s file.  However, your patch changes how the DWARF is emitted.  Really what you should have here is an IR (.ll) file, which you compile to an object with `llc`.  Then you can use llvm-dwarfdump to verify what the backend produces from now on, instead of what it produced one time (when the .s file was created).



================
Comment at: llvm/test/tools/llvm-dwarfdump/ELF/formclass3-atmemloc.s:9
+#     return *E;
+#   }
+# Compile with:
----------------
Eliminate function `foo()` and replace it with `e E;` to make the test case much shorter.


================
Comment at: llvm/test/tools/llvm-dwarfdump/ELF/formclass3-atmemloc.s:14
+# RUN: llvm-mc %s -filetype obj -triple powerpc64le-unknown-unknown -o %t.o
+# RUN: llvm-dwarfdump -debug-info -name g %t.o | FileCheck %s -check-prefix=AT-MEMLOC
+
----------------
Add `-v` to the llvm-dwarfdump options, and that will allow you to verify the FORM directly.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105687



More information about the llvm-commits mailing list