37 lines · plain
1# REQUIRES: x862# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o3# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %p/Inputs/gdb-index-multiple-cu-2.s -o %t1.o4# RUN: ld.lld --gdb-index %t.o %t1.o -o %t 2>&1 | count 05# RUN: llvm-dwarfdump -gdb-index %t | FileCheck %s6 7# %t.o has 2 CUs while %t1 has 1, thus _start in %t1.o should have cuIndex 2.8# attributes << 24 | cuIndex = 48 << 24 | 2 = 0x300000029# CHECK: Constant pool10# CHECK-NEXT: 0(0x0): 0x3000000211 12.section .debug_abbrev,"",@progbits13 .byte 1 # Abbreviation Code14 .byte 17 # DW_TAG_compile_unit15 .byte 0 # DW_CHILDREN_yes16 .byte 0 # EOM(1)17 .byte 0 # EOM(2)18 .byte 019 20.section .debug_info,"",@progbits21.Lcu_begin0:22 .long .Lcu_end0 - .Lcu_begin0 - 423 .short 4 # DWARF version number24 .long 0 # Offset Into Abbrev. Section25 .byte 8 # Address Size26 .byte 1 # Abbrev [1] DW_TAG_compile_unit27 .byte 028.Lcu_end0:29.Lcu_begin1:30 .long .Lcu_end1 - .Lcu_begin1 - 431 .short 4 # DWARF version number32 .long 0 # Offset Into Abbrev. Section33 .byte 8 # Address Size34 .byte 1 # Abbrev [1] DW_TAG_compile_unit35 .byte 036.Lcu_end1:37