[PATCH] D73105: [llvm-readobj] - Add a test for --hash-table option.

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 24 04:08:05 PST 2020


jhenderson added inline comments.


================
Comment at: llvm/test/tools/llvm-readobj/ELF/hash-table.test:72
+## Check we can dump the SHT_HASH section even when an object
+## does not have the section header table.
+
----------------
Perhaps add a comment saying that we simulate no section header table by overriding the ELF header properties.


================
Comment at: llvm/test/tools/llvm-readobj/ELF/hash-table.test:91-92
+  Machine: EM_X86_64
+  SHOff:   0x0
+  SHNum:   0
+Sections:
----------------
grimar wrote:
> jhenderson wrote:
> > Whilst I see what you're doing here, I think the test would be less confusing if you used llvm-objcopy --strip-sections to remove the section header table. You could then use the same input and checks as the first test case(s).
> It will not work, because I need a `PT_DYNAMIC` segment to find `.dynamic` here. YAMLs above does not have it.
> I think we do not want to add it there, as they show we can dump hash table using headers table only.
Okay, makes sense.


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

https://reviews.llvm.org/D73105





More information about the llvm-commits mailing list