1# REQUIRES: x86 2 3## Produce dynamic relocations (symbolic or GOT) for relocations to ifunc 4## defined in a DSO. 5 6# RUN: llvm-mc -filetype=obj -triple=x86_64 %S/Inputs/gnu-ifunc-dso.s -o %t1.o 7# RUN: ld.lld -shared %t1.o -soname=so -o %t1.so 8# RUN: llvm-mc -filetype=obj -triple=x86_64 %s -o %t.o 9# RUN: ld.lld %t.o %t1.so -o %t 10# RUN: llvm-readobj --dyn-relocations %t | FileCheck %s 11# RUN: ld.lld -shared %t.o %t1.so -o %t.so 12# RUN: llvm-readobj --dyn-relocations %t.so | FileCheck %s 13 14# CHECK: Dynamic Relocations { 15# CHECK-NEXT: R_X86_64_64 bar 0x0 16# CHECK-NEXT: R_X86_64_GLOB_DAT foo 0x0 17# CHECK-NEXT: } 18 19.data 20 mov foo@gotpcrel(%rip), %rax 21 .quad bar 22