[PATCH] D112843: [aarch64/mac] Correctly disassemble @TLVPPAGE(OFF) relocs

Nico Weber via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 9 13:39:26 PST 2021


thakis added a comment.

(will update in a bit)



================
Comment at: llvm/test/tools/llvm-objdump/MachO/disassemble-arm64-tlv-modifers.test:7
+
+; RUN: llvm-objdump -r %p/Inputs/macho-tlv.o \
+; RUN:     | FileCheck %s --check-prefix=CHECK-OBJ
----------------
MaskRay wrote:
> Prefer using `llvm-mc` to create the object file. It does duplicate a bit of work which is tested in test/MC, but it makes the test much easier to update. For test/tools directories we try very hard to avoid prebuilt binaries.
Will do in a bit. _All_ tests in llvm/test/tools/llvm-objdump/MachO currently use checked in binaries as far as I can tell, that's why I went with this.


================
Comment at: llvm/test/tools/llvm-objdump/MachO/disassemble-arm64-tlv-modifers.test:12
+
+; CHECK-OBJ: 8 ARM64_RELOC_TLVP_LOAD_PAGEOFF12 _var
+; CHECK-OBJ: 4 ARM64_RELOC_TLVP_LOAD_PAGEOFF12 _var
----------------
MaskRay wrote:
> May be better checking the assembly as well to show that the relocation is attached to the correct instruction.
> Then you'll need `-NEXT:`
Will do, but this part is just moved over from the other test.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D112843/new/

https://reviews.llvm.org/D112843



More information about the llvm-commits mailing list