xref: /llvm-project/bolt/test/X86/checkvma-large-section.test (revision 11791ae7b0b05b8bd8d806331ff51da618912cf8)
1## This test reproduces the issue with a section which ends at >4G address
2REQUIRES: asserts
3RUN: split-file %s %t
4RUN: yaml2obj %t/yaml -o %t.exe --max-size=0
5RUN: llvm-bolt %t.exe -o %t.null --allow-stripped
6#--- yaml
7--- !ELF
8FileHeader:
9  Class: ELFCLASS64
10  Data: ELFDATA2LSB
11  Type: ET_EXEC
12  Machine: EM_X86_64
13ProgramHeaders:
14  - Type: PT_LOAD
15    FirstSec: .a
16    LastSec: .a
17    Align: 0x1000
18  - Type: PT_LOAD
19    Flags: [ PF_R, PF_W ]
20    FirstSec: .large_sec
21    LastSec: .large_sec
22    VAddr: 0x80000000
23  - Type: PT_GNU_RELRO
24    Flags: [ PF_R ]
25Sections:
26  - Name: .a
27    Type: SHT_PROGBITS
28    Content: 00
29    AddressAlign: 0x1
30  - Name: .large_sec
31    Type: SHT_NOBITS
32    Flags: [ SHF_WRITE, SHF_ALLOC ]
33    Address: 0x80000000
34    Size: 0x80000000
35...
36