[ELF] Make SyntheticSection parameter order match InputSection
[llvm-project.git] / lld / test / ELF / compressed-input-err.s
blob83b1f62d7e49571bdc7187cad8ffd9a534bd3933
1 # REQUIRES: zlib
2 # RUN: yaml2obj --docnum=1 %s -o %t1.o
3 # RUN: not ld.lld %t1.o -o /dev/null 2>&1 | FileCheck %s --check-prefix=TOO-SHORT
4 # TOO-SHORT: error: {{.*}}.o:(.debug_info): corrupted compressed section
6 # RUN: yaml2obj --docnum=2 %s -o %t2.o
7 # RUN: not ld.lld %t2.o -o /dev/null 2>&1 | FileCheck %s --check-prefix=UNKNOWN
8 # UNKNOWN: error: {{.*}}.o:(.debug_info): unsupported compression type (3)
10 # RUN: yaml2obj --docnum=3 %s -o %t3.o
11 # RUN: not ld.lld %t3.o -o /dev/null -shared 2>&1 | FileCheck %s
13 ## Check we are able to report zlib decompress errors.
14 # CHECK: error: {{.*}}.o:(.debug_info): decompress failed: zlib error: Z_DATA_ERROR
16 --- !ELF
17 FileHeader:
18 Class: ELFCLASS64
19 Data: ELFDATA2LSB
20 Type: ET_REL
21 Machine: EM_X86_64
22 Sections:
23 - Type: SHT_PROGBITS
24 Name: .debug_info
25 Flags: [ SHF_COMPRESSED ]
26 AddressAlign: 8
27 Content: "0100000000000000040000000000000001000000000000"
29 --- !ELF
30 FileHeader:
31 Class: ELFCLASS64
32 Data: ELFDATA2LSB
33 Type: ET_REL
34 Machine: EM_X86_64
35 Sections:
36 - Type: SHT_PROGBITS
37 Name: .debug_info
38 Flags: [ SHF_COMPRESSED ]
39 AddressAlign: 8
40 Content: "030000000000000000000000000000000100000000000000789c030000000001"
42 --- !ELF
43 FileHeader:
44 Class: ELFCLASS64
45 Data: ELFDATA2LSB
46 Type: ET_REL
47 Machine: EM_X86_64
48 Sections:
49 - Type: SHT_PROGBITS
50 Name: .debug_info
51 Flags: [ SHF_COMPRESSED ]
52 AddressAlign: 8
53 Content: "010000000000000004000000000000000100000000000000ffff"