HomePhabricator

[llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL

Authored by arichardson on Apr 28 2021, 2:13 AM.

Description

[llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL

Previously printing R_386_RELATIVE relocations would trigger
error: can't read an entry at 0x40: it goes past the end of the section (0x40)
I found this while writing a test case for LLD (D100490).
This also includes some minor cleanup in the elf-dynamic-relcos.test
llvm-objdump test based on the newly added test.

Reviewed By: jhenderson, MaskRay

Differential Revision: https://reviews.llvm.org/D100489

Details

Committed
arichardsonApr 28 2021, 4:23 AM
Reviewer
jhenderson
Differential Revision
D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL
Parents
rGaed66d278768: [ELF] Update URL for MIPS TLS wiki page
Branches
Unknown
Tags
Unknown