test: cover subranges with present DW_AT_count attribute
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.dwarf2 / dw2-compdir-oldgcc.S
CommitLineData
1b80a9fa
JK
1/* This testcase is part of GDB, the GNU debugger.
2
ecd75fc8 3 Copyright 2012-2014 Free Software Foundation, Inc.
1b80a9fa
JK
4
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 3 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>. */
17
18 .text
19main: .globl main
20
21gcc42: .globl gcc42
22 .int 0
23 .type gcc42, %function
24 .size gcc42, . - gcc42
25.Lgcc42_procend:
26
27gcc43: .globl gcc43
28 .int 0
29 .type gcc43, %function
30 .size gcc43, . - gcc43
31.Lgcc43_procend:
32
33/* Debug information */
34
35 .section .debug_info
36.Lcu1_begin:
37 /* CU header */
38 .4byte .Lcu1_end - .Lcu1_start /* Length of Compilation Unit */
39.Lcu1_start:
40 .2byte 2 /* DWARF Version */
41 .4byte .Labbrev1_begin /* Offset into abbrev section */
42 .byte 4 /* Pointer size */
43
44 .uleb128 1 /* Abbrev: DW_TAG_compile_unit */
45 .4byte .Lgcc42_begin /* DW_AT_stmt_list */
46 .4byte gcc42 /* DW_AT_low_pc */
47 .4byte .Lgcc42_procend /* DW_AT_high_pc */
48 .ascii "/dir/d/dw2-compdir-oldgcc42.S\0" /* DW_AT_name */
49 .ascii "GNU C 4.2.0\0" /* DW_AT_producer */
50 .byte 1 /* DW_AT_language (C) */
51
52 .uleb128 2 /* Abbrev: DW_TAG_subprogram */
53 .byte 1 /* DW_AT_external */
54 .byte 1 /* DW_AT_decl_file */
55 .byte 1 /* DW_AT_decl_line */
56 .ascii "gcc42\0" /* DW_AT_name */
57 .4byte gcc42 /* DW_AT_low_pc */
58 .4byte .Lgcc42_procend /* DW_AT_high_pc */
59
60 .byte 0 /* End of children of CU */
61.Lcu1_end:
62
63.Lcu2_begin:
64 /* CU header */
65 .4byte .Lcu2_end - .Lcu2_start /* Length of Compilation Unit */
66.Lcu2_start:
67 .2byte 2 /* DWARF Version */
68 .4byte .Labbrev1_begin /* Offset into abbrev section */
69 .byte 4 /* Pointer size */
70
71 .uleb128 1 /* Abbrev: DW_TAG_compile_unit */
72 .4byte .Lgcc43_begin /* DW_AT_stmt_list */
73 .4byte gcc43 /* DW_AT_low_pc */
74 .4byte .Lgcc43_procend /* DW_AT_high_pc */
75 .ascii "/dir/d/dw2-compdir-oldgcc43.S\0" /* DW_AT_name */
76 .ascii "GNU C 4.3.0\0" /* DW_AT_producer */
77 .byte 1 /* DW_AT_language (C) */
78
79 .uleb128 2 /* Abbrev: DW_TAG_subprogram */
80 .byte 1 /* DW_AT_external */
81 .byte 1 /* DW_AT_decl_file */
82 .byte 1 /* DW_AT_decl_line */
83 .ascii "gcc43\0" /* DW_AT_name */
84 .4byte gcc43 /* DW_AT_low_pc */
85 .4byte .Lgcc43_procend /* DW_AT_high_pc */
86
87 .byte 0 /* End of children of CU */
88.Lcu2_end:
89
90/* Abbrev table */
91 .section .debug_abbrev
92.Labbrev1_begin:
93 .uleb128 1 /* Abbrev code */
94 .uleb128 0x11 /* DW_TAG_compile_unit */
95 .byte 1 /* has_children */
96 .uleb128 0x10 /* DW_AT_stmt_list */
97 .uleb128 0x6 /* DW_FORM_data4 */
98 .uleb128 0x11 /* DW_AT_low_pc */
99 .uleb128 0x1 /* DW_FORM_addr */
100 .uleb128 0x12 /* DW_AT_high_pc */
101 .uleb128 0x1 /* DW_FORM_addr */
102 .uleb128 0x3 /* DW_AT_name */
103 .uleb128 0x8 /* DW_FORM_string */
104 .uleb128 0x25 /* DW_AT_producer */
105 .uleb128 0x8 /* DW_FORM_string */
106 .uleb128 0x13 /* DW_AT_language */
107 .uleb128 0xb /* DW_FORM_data1 */
108 .byte 0x0 /* Terminator */
109 .byte 0x0 /* Terminator */
110
111 .uleb128 2 /* Abbrev code */
112 .uleb128 0x2e /* DW_TAG_subprogram */
113 .byte 0 /* has_children */
114 .uleb128 0x3f /* DW_AT_external */
115 .uleb128 0xc /* DW_FORM_flag */
116 .uleb128 0x3a /* DW_AT_decl_file */
117 .uleb128 0xb /* DW_FORM_data1 */
118 .uleb128 0x3b /* DW_AT_decl_line */
119 .uleb128 0xb /* DW_FORM_data1 */
120 .uleb128 0x3 /* DW_AT_name */
121 .uleb128 0x8 /* DW_FORM_string */
122 .uleb128 0x11 /* DW_AT_low_pc */
123 .uleb128 0x1 /* DW_FORM_addr */
124 .uleb128 0x12 /* DW_AT_high_pc */
125 .uleb128 0x1 /* DW_FORM_addr */
126 .byte 0x0 /* Terminator */
127 .byte 0x0 /* Terminator */
128
129 .byte 0x0 /* Terminator */
130 .byte 0x0 /* Terminator */
131
132/* Line table */
133 .section .debug_line
134.Lgcc42_begin:
135 .4byte .Lgcc42_end - .Lgcc42_start /* Initial length */
136.Lgcc42_start:
137 .2byte 2 /* Version */
138 .4byte .Lgcc42_lines - .Lgcc42_hdr /* header_length */
139.Lgcc42_hdr:
140 .byte 1 /* Minimum insn length */
141 .byte 1 /* default_is_stmt */
142 .byte 1 /* line_base */
143 .byte 1 /* line_range */
144 .byte 4 /* opcode_base */
145
146 /* Standard lengths */
147 .byte 0
148 .byte 1
149 .byte 1
150
151 /* Include directories */
152 .byte 0
153
154 /* File names */
155 .ascii "dw2-compdir-oldgcc42.S\0"
156 .uleb128 0 /* directory */
157 .uleb128 0
158 .uleb128 0
159
160 .byte 0
161
162.Lgcc42_lines:
163 .byte 0 /* DW_LNE_set_address */
164 .uleb128 5
165 .byte 2
166 .4byte gcc42
167
168 .byte 3 /* DW_LNS_advance_line */
169 .sleb128 41 /* ... to 42 */
170
171 .byte 1 /* DW_LNS_copy */
172
173 .byte 0 /* DW_LNE_set_address */
174 .uleb128 5
175 .byte 2
176 .4byte .Lgcc42_procend
177
178 .byte 0 /* DW_LNE_end_of_sequence */
179 .uleb128 1
180 .byte 1
181.Lgcc42_end:
182
183.Lgcc43_begin:
184 .4byte .Lgcc43_end - .Lgcc43_start /* Initial length */
185.Lgcc43_start:
186 .2byte 2 /* Version */
187 .4byte .Lgcc43_lines - .Lgcc43_hdr /* header_length */
188.Lgcc43_hdr:
189 .byte 1 /* Minimum insn length */
190 .byte 1 /* default_is_stmt */
191 .byte 1 /* line_base */
192 .byte 1 /* line_range */
193 .byte 4 /* opcode_base */
194
195 /* Standard lengths */
196 .byte 0
197 .byte 1
198 .byte 1
199
200 /* Include directories */
201 .byte 0
202
203 /* File names */
204 .ascii "dw2-compdir-oldgcc43.S\0"
205 .uleb128 0 /* directory */
206 .uleb128 0
207 .uleb128 0
208
209 .byte 0
210
211.Lgcc43_lines:
212 .byte 0 /* DW_LNE_set_address */
213 .uleb128 5
214 .byte 2
215 .4byte gcc43
216
217 .byte 3 /* DW_LNS_advance_line */
218 .sleb128 42 /* ... to 43 */
219
220 .byte 1 /* DW_LNS_copy */
221
222 .byte 0 /* DW_LNE_set_address */
223 .uleb128 5
224 .byte 2
225 .4byte .Lgcc43_procend
226
227 .byte 0 /* DW_LNE_end_of_sequence */
228 .uleb128 1
229 .byte 1
230.Lgcc43_end:
This page took 0.2101 seconds and 4 git commands to generate.