35 lines · plain
1// REQUIRES: x862 3/// Alignment of the copy relocated symbol is respected.4 5// RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o6// RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %p/Inputs/relocation-copy-align.s -o %t2.o7// RUN: ld.lld -shared %t2.o -o %t.so8// RUN: ld.lld %t.o %t.so -o %t39// RUN: llvm-readobj -S -r --expand-relocs %t3 | FileCheck %s10 11.global _start12_start:13movl $5, x14 15// CHECK: Name: .bss16// CHECK-NEXT: Type: SHT_NOBITS17// CHECK-NEXT: Flags [18// CHECK-NEXT: SHF_ALLOC19// CHECK-NEXT: SHF_WRITE20// CHECK-NEXT: ]21// CHECK-NEXT: Address:22// CHECK-NEXT: Offset:23// CHECK-NEXT: Size: 424// CHECK-NEXT: Link:25// CHECK-NEXT: Info:26// CHECK-NEXT: AddressAlignment: 427// CHECK-NEXT: EntrySize:28 29// CHECK: Relocation {30// CHECK-NEXT: Offset:31// CHECK-NEXT: Type: R_X86_64_COPY32// CHECK-NEXT: Symbol: x33// CHECK-NEXT: Addend: 0x034// CHECK-NEXT: }35