Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / lld / test / MachO / invalid / invalid-relocation-length.yaml
blobff8759b417478b118a58ece100c3747b9a1e8e9b
1 # REQUIRES: x86
2 # RUN: yaml2obj %s -o %t.o
3 # RUN: not %lld -o %t %t.o 2>&1 | FileCheck %s -DFILE=%t.o
5 # CHECK: error: UNSIGNED relocation has width 2 bytes, but must be 4 or 8 bytes at offset 1 of __TEXT,__text in [[FILE]]
7 !mach-o
8 FileHeader:
9   magic:           0xFEEDFACF
10   cputype:         0x01000007
11   cpusubtype:      0x00000003
12   filetype:        0x00000001
13   ncmds:           4
14   sizeofcmds:      280
15   flags:           0x00000000
16   reserved:        0x00000000
17 LoadCommands:
18   - cmd:             LC_SEGMENT_64
19     cmdsize:         152
20     segname:         ''
21     vmaddr:          0
22     vmsize:          9
23     fileoff:         312
24     filesize:        9
25     maxprot:         7
26     initprot:        7
27     nsects:          1
28     flags:           0
29     Sections:
30       - sectname:        __text
31         segname:         __TEXT
32         addr:            0x0000000000000000
33         size:            9
34         offset:          0x00000138
35         align:           0
36         reloff:          0x00000144
37         nreloc:          1
38         flags:           0x80000000
39         reserved1:       0x00000000
40         reserved2:       0x00000000
41         reserved3:       0x00000000
42         content:         '000000000000000000'
43         relocations:
44           - address:         0x00000001
45             symbolnum:       1
46             pcrel:           false
47             length:          1
48             extern:          true
49             type:            0
50             scattered:       false
51             value:           0
52   - cmd:             LC_BUILD_VERSION
53     cmdsize:         24
54     platform:        1
55     minos:           659200
56     sdk:             0
57     ntools:          0
58   - cmd:             LC_SYMTAB
59     cmdsize:         24
60     symoff:          332
61     nsyms:           2
62     stroff:          364
63     strsize:         12
64   - cmd:             LC_DYSYMTAB
65     cmdsize:         80
66     ilocalsym:       0
67     nlocalsym:       0
68     iextdefsym:      0
69     nextdefsym:      2
70     iundefsym:       2
71     nundefsym:       0
72     tocoff:          0
73     ntoc:            0
74     modtaboff:       0
75     nmodtab:         0
76     extrefsymoff:    0
77     nextrefsyms:     0
78     indirectsymoff:  0
79     nindirectsyms:   0
80     extreloff:       0
81     nextrel:         0
82     locreloff:       0
83     nlocrel:         0
84 LinkEditData:
85   NameList:
86     - n_strx:          1
87       n_type:          0x0F
88       n_sect:          1
89       n_desc:          0
90       n_value:         1
91     - n_strx:          6
92       n_type:          0x0F
93       n_sect:          1
94       n_desc:          0
95       n_value:         9
96   StringTable:
97     - ''
98     - _foo
99     - _main