[lld] lld/AArch64: handle more relocation addends (PR #87328)

Fangrui Song via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 9 12:41:57 PDT 2024


================
@@ -1,8 +1,36 @@
 ## Test certain REL relocation types generated by legacy armasm.
 # RUN: yaml2obj %s -o %t.o
-# RUN: not ld.lld %t.o -o /dev/null 2>&1 | FileCheck %s
+# RUN: ld.lld %t.o -o %t
+# RUN: llvm-objdump -s %t | FileCheck %s
 
-# CHECK-COUNT-17: internal linker error: cannot read addend
+# CHECK:      Contents of section .abs:
+# CHECK-NEXT:  2000e8 29002800 00002700 00000000 0000fcff  ).(...'.........
----------------
MaskRay wrote:

Replace the address part with `[[#%x,]]` so that the test doesn't need a change in case we change the section layout

https://github.com/llvm/llvm-project/pull/87328


More information about the llvm-commits mailing list