1 # RUN: yaml2obj %s > %t.exe
2 # RUN: llvm-readobj --unwind %t.exe | FileCheck %s
4 # CHECK: EHFrameHeader {
5 # CHECK-NEXT: Address: 0x4013c0
6 # CHECK-NEXT: Offset: 0xbc
7 # CHECK-NEXT: Size: 0x3c
8 # CHECK-NEXT: Corresponding Section: .eh_frame_hdr
10 # CHECK-NEXT: version: 1
11 # CHECK-NEXT: eh_frame_ptr_enc: 0x1b
12 # CHECK-NEXT: fde_count_enc: 0x3
13 # CHECK-NEXT: table_enc: 0x3b
14 # CHECK-NEXT: eh_frame_ptr: 0x401400
15 # CHECK-NEXT: fde_count: 6
16 # CHECK-NEXT: entry 0 {
17 # CHECK-NEXT: initial_location: 0x4004a0
18 # CHECK-NEXT: address: 0x401448
20 # CHECK-NEXT: entry 1 {
21 # CHECK-NEXT: initial_location: 0x4004d0
22 # CHECK-NEXT: address: 0x401418
24 # CHECK-NEXT: entry 2 {
25 # CHECK-NEXT: initial_location: 0x4005b6
26 # CHECK-NEXT: address: 0x401470
28 # CHECK-NEXT: entry 3 {
29 # CHECK-NEXT: initial_location: 0x4005d0
30 # CHECK-NEXT: address: 0x401490
32 # CHECK-NEXT: entry 4 {
33 # CHECK-NEXT: initial_location: 0x401250
34 # CHECK-NEXT: address: 0x4014c0
36 # CHECK-NEXT: entry 5 {
37 # CHECK-NEXT: initial_location: 0x4012c0
38 # CHECK-NEXT: address: 0x4014f0
43 # CHECK: .eh_frame section at offset 0xf8 address 0x401400:
44 # CHECK-NEXT: [0x401400] CIE length=20
45 # CHECK-NEXT: version: 1
46 # CHECK-NEXT: augmentation: zR
47 # CHECK-NEXT: code_alignment_factor: 1
48 # CHECK-NEXT: data_alignment_factor: -8
49 # CHECK-NEXT: return_address_register: 16
52 # CHECK-NEXT: DW_CFA_def_cfa: reg7 +8
53 # CHECK-NEXT: DW_CFA_offset: reg16 -8
54 # CHECK-NEXT: DW_CFA_undefined: reg16
56 # CHECK: [0x401418] FDE length=20 cie=[0x401400]
57 # CHECK-NEXT: initial_location: 0x4004d0
58 # CHECK-NEXT: address_range: 0x2a (end : 0x4004fa)
61 # CHECK-NEXT: DW_CFA_nop:
62 # CHECK-NEXT: DW_CFA_nop:
63 # CHECK-NEXT: DW_CFA_nop:
64 # CHECK-NEXT: DW_CFA_nop:
65 # CHECK-NEXT: DW_CFA_nop:
66 # CHECK-NEXT: DW_CFA_nop:
67 # CHECK-NEXT: DW_CFA_nop:
69 # CHECK: [0x401430] CIE length=20
70 # CHECK-NEXT: version: 1
71 # CHECK-NEXT: augmentation: zR
72 # CHECK-NEXT: code_alignment_factor: 1
73 # CHECK-NEXT: data_alignment_factor: -8
74 # CHECK-NEXT: return_address_register: 16
77 # CHECK-NEXT: DW_CFA_def_cfa: reg7 +8
78 # CHECK-NEXT: DW_CFA_offset: reg16 -8
79 # CHECK-NEXT: DW_CFA_nop:
80 # CHECK-NEXT: DW_CFA_nop:
82 # CHECK: [0x401448] FDE length=36 cie=[0x401430]
83 # CHECK-NEXT: initial_location: 0x4004a0
84 # CHECK-NEXT: address_range: 0x20 (end : 0x4004c0)
87 # CHECK-NEXT: DW_CFA_def_cfa_offset: +16
88 # CHECK-NEXT: DW_CFA_advance_loc: 6
89 # CHECK-NEXT: DW_CFA_def_cfa_offset: +24
90 # CHECK-NEXT: DW_CFA_advance_loc: 10
91 # CHECK-NEXT: DW_CFA_def_cfa_expression: DW_OP_breg7 +8, DW_OP_breg16 +0, DW_OP_lit15, DW_OP_and, DW_OP_lit11, DW_OP_ge, DW_OP_lit3, DW_OP_shl, DW_OP_plus
92 # CHECK-NEXT: DW_CFA_nop:
93 # CHECK-NEXT: DW_CFA_nop:
94 # CHECK-NEXT: DW_CFA_nop:
95 # CHECK-NEXT: DW_CFA_nop:
97 # CHECK: [0x401470] FDE length=28 cie=[0x401430]
98 # CHECK-NEXT: initial_location: 0x4005b6
99 # CHECK-NEXT: address_range: 0x10 (end : 0x4005c6)
102 # CHECK-NEXT: DW_CFA_advance_loc: 1
103 # CHECK-NEXT: DW_CFA_def_cfa_offset: +16
104 # CHECK-NEXT: DW_CFA_offset: reg6 -16
105 # CHECK-NEXT: DW_CFA_advance_loc: 3
106 # CHECK-NEXT: DW_CFA_def_cfa_register: reg6
107 # CHECK-NEXT: DW_CFA_advance_loc: 11
108 # CHECK-NEXT: DW_CFA_def_cfa: reg7 +8
109 # CHECK-NEXT: DW_CFA_nop:
110 # CHECK-NEXT: DW_CFA_nop:
111 # CHECK-NEXT: DW_CFA_nop:
113 # CHECK: [0x401490] FDE length=44 cie=[0x401430]
114 # CHECK-NEXT: initial_location: 0x4005d0
115 # CHECK-NEXT: address_range: 0xc7f (end : 0x40124f)
118 # CHECK-NEXT: DW_CFA_advance_loc: 5
119 # CHECK-NEXT: DW_CFA_def_cfa: reg10 +0
120 # CHECK-NEXT: DW_CFA_advance_loc: 9
121 # CHECK-NEXT: DW_CFA_expression: reg6 DW_OP_breg6 +0
122 # CHECK-NEXT: DW_CFA_advance_loc: 5
123 # CHECK-NEXT: DW_CFA_def_cfa_expression: DW_OP_breg6 -8, DW_OP_deref
124 # CHECK-NEXT: DW_CFA_advance_loc2: 3174
125 # CHECK-NEXT: DW_CFA_def_cfa: reg10 +0
126 # CHECK-NEXT: DW_CFA_advance_loc: 5
127 # CHECK-NEXT: DW_CFA_def_cfa: reg7 +8
128 # CHECK-NEXT: DW_CFA_nop:
129 # CHECK-NEXT: DW_CFA_nop:
130 # CHECK-NEXT: DW_CFA_nop:
131 # CHECK-NEXT: DW_CFA_nop:
133 # CHECK: [0x4014c0] FDE length=44 cie=[0x401430]
134 # CHECK-NEXT: initial_location: 0x401250
135 # CHECK-NEXT: address_range: 0x66 (end : 0x4012b6)
138 # CHECK-NEXT: DW_CFA_advance_loc: 1
139 # CHECK-NEXT: DW_CFA_def_cfa_offset: +16
140 # CHECK-NEXT: DW_CFA_offset: reg6 -16
141 # CHECK-NEXT: DW_CFA_advance_loc: 3
142 # CHECK-NEXT: DW_CFA_def_cfa_register: reg6
143 # CHECK-NEXT: DW_CFA_advance_loc: 2
144 # CHECK-NEXT: DW_CFA_offset: reg15 -24
145 # CHECK-NEXT: DW_CFA_advance_loc: 5
146 # CHECK-NEXT: DW_CFA_offset: reg14 -32
147 # CHECK-NEXT: DW_CFA_advance_loc: 7
148 # CHECK-NEXT: DW_CFA_offset: reg13 -40
149 # CHECK-NEXT: DW_CFA_offset: reg12 -48
150 # CHECK-NEXT: DW_CFA_advance_loc: 8
151 # CHECK-NEXT: DW_CFA_offset: reg3 -56
152 # CHECK-NEXT: DW_CFA_advance_loc1: 75
153 # CHECK-NEXT: DW_CFA_def_cfa: reg7 +8
154 # CHECK-NEXT: DW_CFA_nop:
155 # CHECK-NEXT: DW_CFA_nop:
156 # CHECK-NEXT: DW_CFA_nop:
157 # CHECK-NEXT: DW_CFA_nop:
159 # CHECK: [0x4014f0] FDE length=20 cie=[0x401430]
160 # CHECK-NEXT: initial_location: 0x4012c0
161 # CHECK-NEXT: address_range: 0x1 (end : 0x4012c1)
164 # CHECK-NEXT: DW_CFA_nop:
165 # CHECK-NEXT: DW_CFA_nop:
166 # CHECK-NEXT: DW_CFA_nop:
167 # CHECK-NEXT: DW_CFA_nop:
168 # CHECK-NEXT: DW_CFA_nop:
169 # CHECK-NEXT: DW_CFA_nop:
170 # CHECK-NEXT: DW_CFA_nop:
178 Entry: 0x0000000000400000
182 Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
183 Address: 0x0000000000400000
185 Content: 50C704240020400031C05AC3
186 - Name: .eh_frame_hdr
189 Address: 0x00000000004013c0
191 Content: 011B033B3C00000006000000E0F0FFFF8800000010F1FFFF58000000F6F1FFFFB000000010F2FFFFD000000090FEFFFF0001000000FFFFFF30010000
195 Address: 0x0000000000401400
197 Content: 1400000000000000017A5200017810011B0C070890010710140000001C000000B0F0FFFF2A00000000000000000000001400000000000000017A5200017810011B0C070890010000240000001C00000050F0FFFF20000000000E10460E184A0F0B770880003F1A3B2A332422000000001C000000440000003EF1FFFF1000000000410E108602430D064B0C07080000002C0000006400000038F1FFFF7F0C000000450C0A00491006027600450F0376780603660C0C0A00450C070800000000002C0000009400000088FDFFFF6600000000410E108602430D06428F03458E04478D058C06488307024B0C07080000000014000000C4000000C8FDFFFF01000000000000000000000000000000
202 Value: 0x0000000000400000
206 Flags: [ PF_X, PF_R ]
211 - Type: PT_GNU_EH_FRAME
212 Flags: [ PF_X, PF_R ]
216 - Section: .eh_frame_hdr