[ELF][ARM] Increase default max-page-size from 4096 to 6536
[llvm-project.git] / lld / test / ELF / arm-gotoff.s
blob0a6ea3ab0dad9935e2f12a1575edf2f1a44c140e
1 // REQUIRES: arm
2 // RUN: llvm-mc -filetype=obj -triple=armv7a-linux-gnueabi %s -o %t.o
3 // RUN: ld.lld %t.o -o %t
4 // RUN: llvm-readobj -S -r --symbols %t | FileCheck %s
5 // RUN: llvm-objdump --triple=armv7a-linux-gnueabi -d %t | FileCheck --check-prefix=DISASM %s
7 // Test the R_ARM_GOTOFF32 relocation
9 // CHECK: Name: .got
10 // CHECK-NEXT: Type: SHT_PROGBITS (0x1)
11 // CHECK-NEXT: Flags [
12 // CHECK-NEXT: SHF_ALLOC
13 // CHECK-NEXT: SHF_WRITE
14 // CHECK-NEXT: ]
15 // CHECK-NEXT: Address: 0x30124
16 // CHECK-NEXT: Offset: 0x124
17 // CHECK-NEXT: Size: 0
18 // CHECK-NEXT: Link:
19 // CHECK-NEXT: Info:
20 // CHECK-NEXT: AddressAlignment:
22 // CHECK: Name: .bss
23 // CHECK-NEXT: Type: SHT_NOBITS
24 // CHECK-NEXT: Flags [
25 // CHECK-NEXT: SHF_ALLOC
26 // CHECK-NEXT: SHF_WRITE
27 // CHECK-NEXT: ]
28 // CHECK-NEXT: Address: 0x40124
29 // CHECK-NEXT: Offset:
30 // CHECK-NEXT: Size: 20
31 // CHECK-NEXT: Link:
32 // CHECK-NEXT: Info:
33 // CHECK-NEXT: AddressAlignment: 1
35 // CHECK-NEXT: EntrySize: 0
37 // CHECK: Symbol {
38 // CHECK: Name: bar
39 // CHECK-NEXT: Value: 0x40124
40 // CHECK-NEXT: Size: 10
41 // CHECK-NEXT: Binding: Global
42 // CHECK-NEXT: Type: Object
43 // CHECK-NEXT: Other: 0
44 // CHECK-NEXT: Section: .bss
45 // CHECK-NEXT: }
46 // CHECK-NEXT: Symbol {
47 // CHECK-NEXT: Name: obj
48 // CHECK-NEXT: Value: 0x4012E
49 // CHECK-NEXT: Size: 10
50 // CHECK-NEXT: Binding: Global
51 // CHECK-NEXT: Type: Object
52 // CHECK-NEXT: Other: 0
53 // CHECK-NEXT: Section: .bss
55 // DISASM: Disassembly of section .text:
56 // DISASM-EMPTY:
57 // DISASM-NEXT :_start:
58 // DISASM-NEXT 11114: 1e ff 2f e1 bx lr
59 // Offset 0 from .got = bar
60 // DISASM 11118: 00 10 00 00
61 // Offset 10 from .got = obj
62 // DISASM-NEXT 1111c: 0a 10 00 00
63 // Offset 15 from .got = obj +5
64 // DISASM-NEXT 11120: 0f 10 00 00
65 .syntax unified
66 .globl _start
67 _start:
68 bx lr
69 .word bar(GOTOFF)
70 .word obj(GOTOFF)
71 .word obj(GOTOFF)+5
72 .type bar, %object
73 .comm bar, 10
74 .type obj, %object
75 .comm obj, 10