[ELF] Make section member orders consistent
[llvm-project.git] / lld / test / ELF / arm-thumb2-adr-err.s
blob20ded45e329a8ec79eac3024e0bf74de508a8396
1 // REQUIRES: arm
2 // RUN: llvm-mc --triple=thumbv7m-none-eabi --arm-add-build-attributes -filetype=obj -o %t.o %s
3 // RUN: not ld.lld %t.o -o /dev/null 2>&1 | FileCheck %s
5 .section .text.0, "ax", %progbits
6 .thumb_func
7 .balign 4
8 low:
9 bx lr
10 nop
11 nop
13 .section .text.1, "ax", %progbits
14 .global _start
15 .thumb_func
16 _start:
17 // CHECK: {{.*}}.s.tmp.o:(.text.1+0x0): relocation R_ARM_THM_ALU_PREL_11_0 out of range: 4098 is not in [0, 4095]
18 /// adr.w r0, low - 4091
19 .inst.w 0xf6af70ff
20 .reloc 0, R_ARM_THM_ALU_PREL_11_0, low
21 // CHECK: {{.*}}.s.tmp.o:(.text.1+0x4): relocation R_ARM_THM_ALU_PREL_11_0 out of range: 4096 is not in [0, 4095]
22 /// adr.w r0, high + 4091
23 .inst.w 0xf60f70f7
24 .reloc 4, R_ARM_THM_ALU_PREL_11_0, high
25 .section .text.2
26 .thumb_func
27 .balign 4
28 high:
29 bx lr