[llvm] Do not replace dead constant references in metadata with undef
[llvm-project.git] / lld / test / ELF / rel-offset.s
blob69a96c8032171a6972f1a8e8da51e19cbd661cef
1 // REQUIRES: x86
2 // RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
3 // RUN: ld.lld %t.o -o %t -shared
4 // RUN: llvm-readobj -r %t | FileCheck %s
6 .section .data.foo,"aw",@progbits
7 .quad foo
9 .section .data.zed,"aw",@progbits
10 .quad foo
12 // CHECK: Section ({{.*}}) .rela.dyn {
13 // CHECK-NEXT: 0x3340 R_X86_64_64 foo 0x0
14 // CHECK-NEXT: 0x3348 R_X86_64_64 foo 0x0
15 // CHECK-NEXT: }