[llvm-readelf/obj] - Print section symbol names properly when dumping relocations.
Currently `--relocations` ignores section symbol names and always prints section names for them. This is inconsistent with GNU readelf and with `--symbols`. We have a code in `getFullSymbolName` (which is used for `--symbols`) which can be reused for `getRelocationTarget` (used for `--relocations`). With that the issue described is fixed and code becomes a bit shorter. Also with this change we start to print more relocations (in situations when we just showed warnings instead before) and also start to report more diagnostic warnings (see reloc-zero-name-or-value.test). Differential revision: https://reviews.llvm.org/D87613
Loading
Please sign in to comment