summaryrefslogtreecommitdiff
path: root/Userland/Utilities
diff options
context:
space:
mode:
Diffstat (limited to 'Userland/Utilities')
-rw-r--r--Userland/Utilities/readelf.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/Userland/Utilities/readelf.cpp b/Userland/Utilities/readelf.cpp
index 1946ee3c47..c3183af64c 100644
--- a/Userland/Utilities/readelf.cpp
+++ b/Userland/Utilities/readelf.cpp
@@ -102,6 +102,8 @@ static const char* object_section_header_type_to_string(ElfW(Word) type)
return "GROUP";
case SHT_SYMTAB_SHNDX:
return "SYMTAB_SHNDX";
+ case SHT_RELR:
+ return "RELR";
case SHT_LOOS:
return "SOOS";
case SHT_SUNW_dof:
@@ -534,6 +536,16 @@ int main(int argc, char** argv)
outln();
});
}
+
+ outln();
+
+ size_t relr_count = 0;
+ object->for_each_relr_relocation([&relr_count](auto) { ++relr_count; });
+ if (relr_count != 0) {
+ outln("Relocation section '.relr.dyn' at offset {:#08x} contains {} entries:", object->relr_relocation_section().offset(), object->relr_relocation_section().entry_count());
+ outln("{:>8x} offsets", relr_count);
+ object->for_each_relr_relocation([](auto offset) { outln("{:p}", offset); });
+ }
} else {
outln("No relocations in this file.");
}