Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / lld / test / ELF / aarch64-got-weak-undef.s
blob62172b173df39e2c5359dae6ec4702d5d0ae4a4a
1 // REQUIRES: aarch64
2 // RUN: llvm-mc -filetype=obj -triple=aarch64-none-freebsd %s -o %t.o
3 // RUN: ld.lld %t.o -o %t
4 // RUN: llvm-readelf -r %t | FileCheck --check-prefix=RELOC %s
5 // RUN: llvm-readelf -x .got %t | FileCheck %s
7 // RELOC: no relocations
9 // CHECK: 0x002201a0 00000000 00000000
11 .globl _start
12 _start:
13 adrp x8, :got:foo
14 ldr x8, [x8, :got_lo12:foo]
15 ldr w0, [x8]
16 ret
18 .weak foo