llvm-project/llvm/test/Object/X86
Fangrui Song 87de9a0786 [X86InstPrinter] Change printPCRelImm to print the target address in hexadecimal form
```
// llvm-objdump -d output (before)
400000: e8 0b 00 00 00   callq 11
400005: e8 0b 00 00 00   callq 11

// llvm-objdump -d output (after)
400000: e8 0b 00 00 00  callq 0x400010
400005: e8 0b 00 00 00  callq 0x400015

// GNU objdump -d. The lack of 0x is not ideal because the result cannot be re-assembled
400000: e8 0b 00 00 00  callq 400010
400005: e8 0b 00 00 00  callq 400015
```

In llvm-objdump, we pass the address of the next MCInst. Ideally we
should just thread the address of the current address, unfortunately we
cannot call X86MCCodeEmitter::encodeInstruction (X86MCCodeEmitter
requires MCInstrInfo and MCContext) to get the length of the MCInst.

MCInstPrinter::printInst has other callers (e.g llvm-mc -filetype=asm, llvm-mca) which set Address to 0.
They leave MCInstPrinter::PrintBranchImmAsAddress as false and this change is a no-op for them.

Reviewed By: jhenderson

Differential Revision: https://reviews.llvm.org/D76580
2020-03-26 08:28:59 -07:00
..
archive-ir-asm.ll
archive-symbol-table.s
asm-lazy-reference.ll
coff-asm.ll
irsymtab-asm.ll
irsymtab-bad-alias.ll
irsymtab.ll Add IR support, ELF section and user documentation for partitioning feature. 2019-05-29 03:29:01 +00:00
lit.local.cfg [lit] Delete empty lines at the end of lit.local.cfg NFC 2019-06-17 09:51:07 +00:00
macho-text-sections.test [test] llvm/test/: change llvm-objdump single-dash long options to double-dash options 2020-03-15 17:46:23 -07:00
nm-bitcodeweak.test
nm-coff.s MC: correct the emission of weak aliases in COFF 2019-06-26 01:09:52 +00:00
nm-ir.ll
nm-macho.s
nm-print-size.s
nm-undefinedweak.test
obj2yaml-dup-section-name.s [yaml2obj/obj2yaml] - Allow having the symbols and sections with duplicated names. 2019-06-25 08:22:57 +00:00
obj2yaml-dup-symbol-name.s
objdump-disassembly-inline-relocations.test [X86InstPrinter] Change printPCRelImm to print the target address in hexadecimal form 2020-03-26 08:28:59 -07:00
objdump-label.test [llvm-objdump] -d: print `00000000 <foo>:` instead of `00000000 foo:` 2020-03-05 18:05:28 -08:00
objdump-trivial-object.test [X86InstPrinter] Change printPCRelImm to print the target address in hexadecimal form 2020-03-26 08:28:59 -07:00
yaml2obj-elf-x86-rel.yaml [lib/ObjectYAML] - Make `ELFYAML::Relocation::Offset` optional. 2020-03-06 13:59:58 +03:00