1 # RUN: llvm-mc -triple x86_64-unknown-linux %s -filetype=obj -o %t.dwp
2 # RUN: not llvm-dwp %t.dwp -o /dev/null 2>&1 | FileCheck %s
4 ## Note: To reach the test point, we need to use comdat groups, to have multiple
5 ## .debug_info sections. One comdat group needs to have one complete unit header,
6 ## the second one may be completely empty.
7 ## Furthermore, the .debug_cu_index also does not need to be complete.
9 # CHECK: error: expected exactly one occurrence of a debug info section in a .dwp file
10 .section .debug_info.dwo,"G",@progbits,0xFDFDFDFD,comdat
11 .long .Ldebug_info_dwo_end1-.Ldebug_info_dwo_start1 # Length of Unit
12 .Ldebug_info_dwo_start1:
13 .short 5 # DWARF version number
14 .byte 5 # DWARF Unit Type (DW_UT_split_compile)
15 .byte 8 # Address Size (in bytes)
16 .long 0 # Offset Into Abbrev. Section
17 .quad -1506010254921578184
18 .byte 1 # Abbrev [1] DW_TAG_compile_unit
19 .Ldebug_info_dwo_end1:
20 .section .debug_info.dwo,"G",@progbits,0xDFDFDFDF,comdat
21 .long 0 # Length of Unit
22 .section .debug_cu_index, "", @progbits