25 lines · plain
1# REQUIRES: x862 3## Test canonical PLT can be created for -no-pie and -pie.4 5# RUN: llvm-mc -filetype=obj -triple=x86_64 %s -o %t.o6# RUN: llvm-mc -filetype=obj -triple=x86_64 %p/Inputs/canonical-plt-pcrel.s -o %t1.o7# RUN: ld.lld %t1.o -o %t1.so -shared -soname=so8 9# RUN: ld.lld %t.o %t1.so -o %t10# RUN: llvm-readobj -r %t | FileCheck %s11 12# RUN: ld.lld %t.o %t1.so -o %t -pie13# RUN: llvm-readobj -r %t | FileCheck %s14 15# CHECK: Relocations [16# CHECK-NEXT: .rela.plt {17# CHECK-NEXT: R_X86_64_JUMP_SLOT func 0x018# CHECK-NEXT: R_X86_64_JUMP_SLOT ifunc 0x019# CHECK-NEXT: }20# CHECK-NEXT: ]21 22.rodata23 .quad func # STT_FUNC24 .quad ifunc # STT_GNU_IFUNC25