xref: /llvm-project/lld/test/ELF/invalid/section-alignment.test (revision 7db789b5702714ffb6c96ad53c3136ca0a4300b2)
1# RUN: yaml2obj %s -o %t
2# RUN: not ld.lld %t -o /dev/null 2>&1 | FileCheck %s
3# RUN: ld.lld %t -o /dev/null --noinhibit-exec 2>&1 | FileCheck %s
4
5## In current lld implementation, we do not accept sh_addralign
6## larger than UINT32_MAX.
7!ELF
8FileHeader:
9  Class:           ELFCLASS64
10  Data:            ELFDATA2LSB
11  Type:            ET_REL
12  Machine:         EM_X86_64
13Sections:
14  - Name:            .text
15    Type:            SHT_PROGBITS
16    Flags:           [ SHF_ALLOC, SHF_EXECINSTR ]
17    AddressAlign:    0x1000000000000000
18    Offset:          0x100
19    Content:         "00000000"
20
21# CHECK: section sh_addralign is too large
22