hanchenye-llvm-project/llvm/test/tools/llvm-objdump
James Henderson 9bc817a0ae [yaml2obj]Allow explicit symbol indexes in relocations and emit error for bad names
Prior to this change, the "Symbol" field of a relocation would always be
assumed to be a symbol name, and if no such symbol existed, the
relocation would reference index 0. This confused me when I tried to use
a literal symbol index in the field: since "0x1" was not a known symbol
name, the symbol index was set as 0. This change falls back to treating
unknown symbol names as integers, and emits an error if the name is not
found and the string is not an integer.

Note that the Symbol field is optional, so if a relocation doesn't
reference a symbol, it shouldn't be specified. The new error required a
number of test updates.

Reviewed by: grimar, ruiu
Differential Revision: https://reviews.llvm.org/D58510

llvm-svn: 355938
2019-03-12 17:00:25 +00:00
..
AArch64 Revert "Revert "[llvm-objdump] Allow short options without arguments to be grouped"" 2019-02-19 19:46:08 +00:00
AMDGPU
ARM [llvm-objdump] Implement -Mreg-names-raw/-std options. 2019-02-26 12:15:14 +00:00
Hexagon
Inputs [WebAssembly] Store section alignment as a power of 2 2019-01-16 01:34:48 +00:00
Mips
PowerPC [PowerPC] Fix printing of negative offsets in call instruction dissasembly. 2019-02-12 17:48:22 +00:00
WebAssembly [WebAssembly] Remove uses of ThreadModel 2019-02-28 18:39:08 +00:00
X86 [yaml2obj]Allow explicit symbol indexes in relocations and emit error for bad names 2019-03-12 17:00:25 +00:00
all-headers.test [llvm-objdump] - Dump the archive headers when -all-headers is specified. 2019-01-18 12:01:59 +00:00
archive-headers.test
call-absolute-symbol-elf.test
coff-file.test
coff-import-library.test
coff-large-bss.test
coff-many-relocs.test
coff-non-null-terminated-file.test
coff-private-headers.test
common-symbol-elf.test
eh_frame-arm64.test
eh_frame-coff.test [DebugInfo] Fix the type of the formated variable 2019-03-07 16:31:08 +00:00
eh_frame-mipsel.test
eh_frame_zero_cie.test
elf-dynamic-section.test [llvm-objdump] Should print unknown d_tag in hex format 2019-03-02 04:20:28 +00:00
embedded-source.test
file-headers-coff.test
file-headers-elf.test
file-headers-pe.test
file-headers-unsupported.test
full-contents.test
hex-relocation-addr.test
invalid-input.test
macho-LLVM-bundle.test
macho-bad-bind.test
macho-bad-dysymtab.test
macho-bad-ordinal.test
macho-bad-trie.test
macho-bind.test
macho-bind2.test
macho-compact-unwind-i386.test
macho-compact-unwind-x86_64.test
macho-exports-trie.test
macho-lazy-bind.test
macho-objc-meta-data.test
macho-rebase.test
macho-sections.test
macho-unwind-info-arm64.test
macho-unwind-info-no-relocs.test
macho-unwind-info-x86_64.test
macho-weak-bind.test
malformed-archives.test
malformed-macho.test
malformed-unwind-x86_64.test
non-archive-object.test
option-grouping.test Revert "Revert "[llvm-objdump] Allow short options without arguments to be grouped"" 2019-02-19 19:46:08 +00:00
private-headers-dynamic-section.test
private-headers-no-dynamic-segment.test [yaml2obj][obj2yaml] - Add support for dumping/parsing .dynamic sections. 2019-02-09 11:34:28 +00:00
private-headers-no-dynamic.test
proc-specific-section-elf.test
relocations-elf.test
section-filter.test
symbol-table-elf.test
verdef-elf.test [llvm-objdump] Add `Version Definitions` dumper 2019-02-26 13:06:16 +00:00
verneed-elf.test [llvm-objdump] Add `Version References` dumper 2019-02-25 13:13:19 +00:00
verneed-wrong-info.test [llvm-objdump] Add `Version References` dumper 2019-02-25 13:13:19 +00:00
wasm-corrupt-section.test
wasm.txt [llvm-objdump] - Print LMAs when dumping section headers. 2019-01-28 14:11:35 +00:00
win64-unwind-data.test