1# struct Foo { 2# char *c1; 3# char *c2; 4# char *c3; 5# }; 6# struct Foo2 { 7# char *c1; 8# char *c2; 9# }; 10# int main(int argc, char *argv[]) { 11# Foo f; 12# f.c1 = argv[argc]; 13# f.c2 = argv[argc + 1]; 14# f.c3 = argv[argc + 2]; 15# Foo2 f2; 16# f.c1 = argv[argc + 3]; 17# f.c2 = argv[argc + 4]; 18# return 0; 19# } 20 21 .text 22 .file "main.cpp" 23 .globl main # -- Begin function main 24 .p2align 4, 0x90 25 .type main,@function 26main: # @main 27.Lfunc_begin0: 28 .file 1 "/dwarf4-types-dwarf5-types-test" "main.cpp" 29 .loc 1 10 0 # main.cpp:10:0 30 .cfi_startproc 31# %bb.0: 32 pushq %rbp 33 .cfi_def_cfa_offset 16 34 .cfi_offset %rbp, -16 35 movq %rsp, %rbp 36 .cfi_def_cfa_register %rbp 37 movl $0, -4(%rbp) 38 movl %edi, -8(%rbp) 39 movq %rsi, -16(%rbp) 40.Ltmp0: 41 .loc 1 12 9 prologue_end # main.cpp:12:9 42 movq -16(%rbp), %rax 43 movslq -8(%rbp), %rcx 44 movq (%rax,%rcx,8), %rax 45 .loc 1 12 7 is_stmt 0 # main.cpp:12:7 46 movq %rax, -40(%rbp) 47 .loc 1 13 9 is_stmt 1 # main.cpp:13:9 48 movq -16(%rbp), %rax 49 .loc 1 13 14 is_stmt 0 # main.cpp:13:14 50 movl -8(%rbp), %ecx 51 .loc 1 13 19 # main.cpp:13:19 52 addl $1, %ecx 53 .loc 1 13 9 # main.cpp:13:9 54 movslq %ecx, %rcx 55 movq (%rax,%rcx,8), %rax 56 .loc 1 13 7 # main.cpp:13:7 57 movq %rax, -32(%rbp) 58 .loc 1 14 9 is_stmt 1 # main.cpp:14:9 59 movq -16(%rbp), %rax 60 .loc 1 14 14 is_stmt 0 # main.cpp:14:14 61 movl -8(%rbp), %ecx 62 .loc 1 14 19 # main.cpp:14:19 63 addl $2, %ecx 64 .loc 1 14 9 # main.cpp:14:9 65 movslq %ecx, %rcx 66 movq (%rax,%rcx,8), %rax 67 .loc 1 14 7 # main.cpp:14:7 68 movq %rax, -24(%rbp) 69 .loc 1 16 9 is_stmt 1 # main.cpp:16:9 70 movq -16(%rbp), %rax 71 .loc 1 16 14 is_stmt 0 # main.cpp:16:14 72 movl -8(%rbp), %ecx 73 .loc 1 16 19 # main.cpp:16:19 74 addl $3, %ecx 75 .loc 1 16 9 # main.cpp:16:9 76 movslq %ecx, %rcx 77 movq (%rax,%rcx,8), %rax 78 .loc 1 16 7 # main.cpp:16:7 79 movq %rax, -40(%rbp) 80 .loc 1 17 9 is_stmt 1 # main.cpp:17:9 81 movq -16(%rbp), %rax 82 .loc 1 17 14 is_stmt 0 # main.cpp:17:14 83 movl -8(%rbp), %ecx 84 .loc 1 17 19 # main.cpp:17:19 85 addl $4, %ecx 86 .loc 1 17 9 # main.cpp:17:9 87 movslq %ecx, %rcx 88 movq (%rax,%rcx,8), %rax 89 .loc 1 17 7 # main.cpp:17:7 90 movq %rax, -32(%rbp) 91 .loc 1 18 2 is_stmt 1 # main.cpp:18:2 92 xorl %eax, %eax 93 .loc 1 18 2 epilogue_begin is_stmt 0 # main.cpp:18:2 94 popq %rbp 95 .cfi_def_cfa %rsp, 8 96 retq 97.Ltmp1: 98.Lfunc_end0: 99 .size main, .Lfunc_end0-main 100 .cfi_endproc 101 # -- End function 102 .section .debug_types,"G",@progbits,7448148824980338162,comdat 103 .long .Ldebug_info_end0-.Ldebug_info_start0 # Length of Unit 104.Ldebug_info_start0: 105 .short 4 # DWARF version number 106 .long .debug_abbrev # Offset Into Abbrev. Section 107 .byte 8 # Address Size (in bytes) 108 .quad 7448148824980338162 # Type Signature 109 .long 30 # Type DIE Offset 110 .byte 1 # Abbrev [1] 0x17:0x42 DW_TAG_type_unit 111 .short 33 # DW_AT_language 112 .long .Lline_table_start0 # DW_AT_stmt_list 113 .byte 2 # Abbrev [2] 0x1e:0x2e DW_TAG_structure_type 114 .byte 5 # DW_AT_calling_convention 115 .long .Linfo_string12 # DW_AT_name 116 .byte 24 # DW_AT_byte_size 117 .byte 1 # DW_AT_decl_file 118 .byte 1 # DW_AT_decl_line 119 .byte 3 # Abbrev [3] 0x27:0xc DW_TAG_member 120 .long .Linfo_string9 # DW_AT_name 121 .long 76 # DW_AT_type 122 .byte 1 # DW_AT_decl_file 123 .byte 2 # DW_AT_decl_line 124 .byte 0 # DW_AT_data_member_location 125 .byte 3 # Abbrev [3] 0x33:0xc DW_TAG_member 126 .long .Linfo_string10 # DW_AT_name 127 .long 76 # DW_AT_type 128 .byte 1 # DW_AT_decl_file 129 .byte 3 # DW_AT_decl_line 130 .byte 8 # DW_AT_data_member_location 131 .byte 3 # Abbrev [3] 0x3f:0xc DW_TAG_member 132 .long .Linfo_string11 # DW_AT_name 133 .long 76 # DW_AT_type 134 .byte 1 # DW_AT_decl_file 135 .byte 4 # DW_AT_decl_line 136 .byte 16 # DW_AT_data_member_location 137 .byte 0 # End Of Children Mark 138 .byte 4 # Abbrev [4] 0x4c:0x5 DW_TAG_pointer_type 139 .long 81 # DW_AT_type 140 .byte 5 # Abbrev [5] 0x51:0x7 DW_TAG_base_type 141 .long .Linfo_string7 # DW_AT_name 142 .byte 6 # DW_AT_encoding 143 .byte 1 # DW_AT_byte_size 144 .byte 0 # End Of Children Mark 145.Ldebug_info_end0: 146 .section .debug_types,"G",@progbits,5322170643381124694,comdat 147 .long .Ldebug_info_end1-.Ldebug_info_start1 # Length of Unit 148.Ldebug_info_start1: 149 .short 4 # DWARF version number 150 .long .debug_abbrev # Offset Into Abbrev. Section 151 .byte 8 # Address Size (in bytes) 152 .quad 5322170643381124694 # Type Signature 153 .long 30 # Type DIE Offset 154 .byte 1 # Abbrev [1] 0x17:0x36 DW_TAG_type_unit 155 .short 33 # DW_AT_language 156 .long .Lline_table_start0 # DW_AT_stmt_list 157 .byte 2 # Abbrev [2] 0x1e:0x22 DW_TAG_structure_type 158 .byte 5 # DW_AT_calling_convention 159 .long .Linfo_string14 # DW_AT_name 160 .byte 16 # DW_AT_byte_size 161 .byte 1 # DW_AT_decl_file 162 .byte 6 # DW_AT_decl_line 163 .byte 3 # Abbrev [3] 0x27:0xc DW_TAG_member 164 .long .Linfo_string9 # DW_AT_name 165 .long 64 # DW_AT_type 166 .byte 1 # DW_AT_decl_file 167 .byte 7 # DW_AT_decl_line 168 .byte 0 # DW_AT_data_member_location 169 .byte 3 # Abbrev [3] 0x33:0xc DW_TAG_member 170 .long .Linfo_string10 # DW_AT_name 171 .long 64 # DW_AT_type 172 .byte 1 # DW_AT_decl_file 173 .byte 8 # DW_AT_decl_line 174 .byte 8 # DW_AT_data_member_location 175 .byte 0 # End Of Children Mark 176 .byte 4 # Abbrev [4] 0x40:0x5 DW_TAG_pointer_type 177 .long 69 # DW_AT_type 178 .byte 5 # Abbrev [5] 0x45:0x7 DW_TAG_base_type 179 .long .Linfo_string7 # DW_AT_name 180 .byte 6 # DW_AT_encoding 181 .byte 1 # DW_AT_byte_size 182 .byte 0 # End Of Children Mark 183.Ldebug_info_end1: 184 .section .debug_abbrev,"",@progbits 185 .byte 1 # Abbreviation Code 186 .byte 65 # DW_TAG_type_unit 187 .byte 1 # DW_CHILDREN_yes 188 .byte 19 # DW_AT_language 189 .byte 5 # DW_FORM_data2 190 .byte 16 # DW_AT_stmt_list 191 .byte 23 # DW_FORM_sec_offset 192 .byte 0 # EOM(1) 193 .byte 0 # EOM(2) 194 .byte 2 # Abbreviation Code 195 .byte 19 # DW_TAG_structure_type 196 .byte 1 # DW_CHILDREN_yes 197 .byte 54 # DW_AT_calling_convention 198 .byte 11 # DW_FORM_data1 199 .byte 3 # DW_AT_name 200 .byte 14 # DW_FORM_strp 201 .byte 11 # DW_AT_byte_size 202 .byte 11 # DW_FORM_data1 203 .byte 58 # DW_AT_decl_file 204 .byte 11 # DW_FORM_data1 205 .byte 59 # DW_AT_decl_line 206 .byte 11 # DW_FORM_data1 207 .byte 0 # EOM(1) 208 .byte 0 # EOM(2) 209 .byte 3 # Abbreviation Code 210 .byte 13 # DW_TAG_member 211 .byte 0 # DW_CHILDREN_no 212 .byte 3 # DW_AT_name 213 .byte 14 # DW_FORM_strp 214 .byte 73 # DW_AT_type 215 .byte 19 # DW_FORM_ref4 216 .byte 58 # DW_AT_decl_file 217 .byte 11 # DW_FORM_data1 218 .byte 59 # DW_AT_decl_line 219 .byte 11 # DW_FORM_data1 220 .byte 56 # DW_AT_data_member_location 221 .byte 11 # DW_FORM_data1 222 .byte 0 # EOM(1) 223 .byte 0 # EOM(2) 224 .byte 4 # Abbreviation Code 225 .byte 15 # DW_TAG_pointer_type 226 .byte 0 # DW_CHILDREN_no 227 .byte 73 # DW_AT_type 228 .byte 19 # DW_FORM_ref4 229 .byte 0 # EOM(1) 230 .byte 0 # EOM(2) 231 .byte 5 # Abbreviation Code 232 .byte 36 # DW_TAG_base_type 233 .byte 0 # DW_CHILDREN_no 234 .byte 3 # DW_AT_name 235 .byte 14 # DW_FORM_strp 236 .byte 62 # DW_AT_encoding 237 .byte 11 # DW_FORM_data1 238 .byte 11 # DW_AT_byte_size 239 .byte 11 # DW_FORM_data1 240 .byte 0 # EOM(1) 241 .byte 0 # EOM(2) 242 .byte 6 # Abbreviation Code 243 .byte 17 # DW_TAG_compile_unit 244 .byte 1 # DW_CHILDREN_yes 245 .byte 37 # DW_AT_producer 246 .byte 14 # DW_FORM_strp 247 .byte 19 # DW_AT_language 248 .byte 5 # DW_FORM_data2 249 .byte 3 # DW_AT_name 250 .byte 14 # DW_FORM_strp 251 .byte 16 # DW_AT_stmt_list 252 .byte 23 # DW_FORM_sec_offset 253 .byte 27 # DW_AT_comp_dir 254 .byte 14 # DW_FORM_strp 255 .byte 17 # DW_AT_low_pc 256 .byte 1 # DW_FORM_addr 257 .byte 18 # DW_AT_high_pc 258 .byte 6 # DW_FORM_data4 259 .byte 0 # EOM(1) 260 .byte 0 # EOM(2) 261 .byte 7 # Abbreviation Code 262 .byte 46 # DW_TAG_subprogram 263 .byte 1 # DW_CHILDREN_yes 264 .byte 17 # DW_AT_low_pc 265 .byte 1 # DW_FORM_addr 266 .byte 18 # DW_AT_high_pc 267 .byte 6 # DW_FORM_data4 268 .byte 64 # DW_AT_frame_base 269 .byte 24 # DW_FORM_exprloc 270 .byte 3 # DW_AT_name 271 .byte 14 # DW_FORM_strp 272 .byte 58 # DW_AT_decl_file 273 .byte 11 # DW_FORM_data1 274 .byte 59 # DW_AT_decl_line 275 .byte 11 # DW_FORM_data1 276 .byte 73 # DW_AT_type 277 .byte 19 # DW_FORM_ref4 278 .byte 63 # DW_AT_external 279 .byte 25 # DW_FORM_flag_present 280 .byte 0 # EOM(1) 281 .byte 0 # EOM(2) 282 .byte 8 # Abbreviation Code 283 .byte 5 # DW_TAG_formal_parameter 284 .byte 0 # DW_CHILDREN_no 285 .byte 2 # DW_AT_location 286 .byte 24 # DW_FORM_exprloc 287 .byte 3 # DW_AT_name 288 .byte 14 # DW_FORM_strp 289 .byte 58 # DW_AT_decl_file 290 .byte 11 # DW_FORM_data1 291 .byte 59 # DW_AT_decl_line 292 .byte 11 # DW_FORM_data1 293 .byte 73 # DW_AT_type 294 .byte 19 # DW_FORM_ref4 295 .byte 0 # EOM(1) 296 .byte 0 # EOM(2) 297 .byte 9 # Abbreviation Code 298 .byte 52 # DW_TAG_variable 299 .byte 0 # DW_CHILDREN_no 300 .byte 2 # DW_AT_location 301 .byte 24 # DW_FORM_exprloc 302 .byte 3 # DW_AT_name 303 .byte 14 # DW_FORM_strp 304 .byte 58 # DW_AT_decl_file 305 .byte 11 # DW_FORM_data1 306 .byte 59 # DW_AT_decl_line 307 .byte 11 # DW_FORM_data1 308 .byte 73 # DW_AT_type 309 .byte 19 # DW_FORM_ref4 310 .byte 0 # EOM(1) 311 .byte 0 # EOM(2) 312 .byte 10 # Abbreviation Code 313 .byte 19 # DW_TAG_structure_type 314 .byte 0 # DW_CHILDREN_no 315 .byte 60 # DW_AT_declaration 316 .byte 25 # DW_FORM_flag_present 317 .byte 105 # DW_AT_signature 318 .byte 32 # DW_FORM_ref_sig8 319 .byte 0 # EOM(1) 320 .byte 0 # EOM(2) 321 .byte 0 # EOM(3) 322 .section .debug_info,"",@progbits 323.Lcu_begin0: 324 .long .Ldebug_info_end2-.Ldebug_info_start2 # Length of Unit 325.Ldebug_info_start2: 326 .short 4 # DWARF version number 327 .long .debug_abbrev # Offset Into Abbrev. Section 328 .byte 8 # Address Size (in bytes) 329 .byte 6 # Abbrev [6] 0xb:0x9c DW_TAG_compile_unit 330 .long .Linfo_string0 # DW_AT_producer 331 .short 33 # DW_AT_language 332 .long .Linfo_string1 # DW_AT_name 333 .long .Lline_table_start0 # DW_AT_stmt_list 334 .long .Linfo_string2 # DW_AT_comp_dir 335 .quad .Lfunc_begin0 # DW_AT_low_pc 336 .long .Lfunc_end0-.Lfunc_begin0 # DW_AT_high_pc 337 .byte 7 # Abbrev [7] 0x2a:0x52 DW_TAG_subprogram 338 .quad .Lfunc_begin0 # DW_AT_low_pc 339 .long .Lfunc_end0-.Lfunc_begin0 # DW_AT_high_pc 340 .byte 1 # DW_AT_frame_base 341 .byte 86 342 .long .Linfo_string3 # DW_AT_name 343 .byte 1 # DW_AT_decl_file 344 .byte 10 # DW_AT_decl_line 345 .long 124 # DW_AT_type 346 # DW_AT_external 347 .byte 8 # Abbrev [8] 0x43:0xe DW_TAG_formal_parameter 348 .byte 2 # DW_AT_location 349 .byte 145 350 .byte 120 351 .long .Linfo_string5 # DW_AT_name 352 .byte 1 # DW_AT_decl_file 353 .byte 10 # DW_AT_decl_line 354 .long 124 # DW_AT_type 355 .byte 8 # Abbrev [8] 0x51:0xe DW_TAG_formal_parameter 356 .byte 2 # DW_AT_location 357 .byte 145 358 .byte 112 359 .long .Linfo_string6 # DW_AT_name 360 .byte 1 # DW_AT_decl_file 361 .byte 10 # DW_AT_decl_line 362 .long 131 # DW_AT_type 363 .byte 9 # Abbrev [9] 0x5f:0xe DW_TAG_variable 364 .byte 2 # DW_AT_location 365 .byte 145 366 .byte 88 367 .long .Linfo_string8 # DW_AT_name 368 .byte 1 # DW_AT_decl_file 369 .byte 11 # DW_AT_decl_line 370 .long 148 # DW_AT_type 371 .byte 9 # Abbrev [9] 0x6d:0xe DW_TAG_variable 372 .byte 2 # DW_AT_location 373 .byte 145 374 .byte 72 375 .long .Linfo_string13 # DW_AT_name 376 .byte 1 # DW_AT_decl_file 377 .byte 15 # DW_AT_decl_line 378 .long 157 # DW_AT_type 379 .byte 0 # End Of Children Mark 380 .byte 5 # Abbrev [5] 0x7c:0x7 DW_TAG_base_type 381 .long .Linfo_string4 # DW_AT_name 382 .byte 5 # DW_AT_encoding 383 .byte 4 # DW_AT_byte_size 384 .byte 4 # Abbrev [4] 0x83:0x5 DW_TAG_pointer_type 385 .long 136 # DW_AT_type 386 .byte 4 # Abbrev [4] 0x88:0x5 DW_TAG_pointer_type 387 .long 141 # DW_AT_type 388 .byte 5 # Abbrev [5] 0x8d:0x7 DW_TAG_base_type 389 .long .Linfo_string7 # DW_AT_name 390 .byte 6 # DW_AT_encoding 391 .byte 1 # DW_AT_byte_size 392 .byte 10 # Abbrev [10] 0x94:0x9 DW_TAG_structure_type 393 # DW_AT_declaration 394 .quad 7448148824980338162 # DW_AT_signature 395 .byte 10 # Abbrev [10] 0x9d:0x9 DW_TAG_structure_type 396 # DW_AT_declaration 397 .quad 5322170643381124694 # DW_AT_signature 398 .byte 0 # End Of Children Mark 399.Ldebug_info_end2: 400 .section .debug_str,"MS",@progbits,1 401.Linfo_string0: 402 .asciz "clang version 15.0.0" # string offset=0 403.Linfo_string1: 404 .asciz "main.cpp" # string offset=146 405.Linfo_string2: 406 .asciz "/dwarf4-types-dwarf5-types-test" # string offset=155 407.Linfo_string3: 408 .asciz "main" # string offset=224 409.Linfo_string4: 410 .asciz "int" # string offset=229 411.Linfo_string5: 412 .asciz "argc" # string offset=233 413.Linfo_string6: 414 .asciz "argv" # string offset=238 415.Linfo_string7: 416 .asciz "char" # string offset=243 417.Linfo_string8: 418 .asciz "f" # string offset=248 419.Linfo_string9: 420 .asciz "c1" # string offset=250 421.Linfo_string10: 422 .asciz "c2" # string offset=253 423.Linfo_string11: 424 .asciz "c3" # string offset=256 425.Linfo_string12: 426 .asciz "Foo" # string offset=259 427.Linfo_string13: 428 .asciz "f2" # string offset=263 429.Linfo_string14: 430 .asciz "Foo2" # string offset=266 431 .ident "clang version 15.0.0" 432 .section ".note.GNU-stack","",@progbits 433 .addrsig 434 .section .debug_line,"",@progbits 435.Lline_table_start0: 436