1 # RUN: llvm-mc -triple x86_64-unknown-linux %s -filetype=obj -o %t.dwp
2 # RUN: not llvm-dwp %t.dwp -o %t 2>&1 | FileCheck %s
4 ## Note: To reach the test point, we need a DWP file with a CU, a CU index
5 ## of version 2 and a TU index of version 5. A valid TU is not required, but
6 ## the .debug_types.dwo section should not be empty.
8 # CHECK: error: incompatible tu_index versions, found 5 and expecting 2
10 .section .debug_abbrev.dwo, "e", @progbits
12 .uleb128 1 # Abbreviation Code
13 .uleb128 17 # DW_TAG_compile_unit
14 .byte 1 # DW_CHILDREN_no
15 .uleb128 0x2131 # DW_AT_GNU_dwo_id
16 .uleb128 7 # DW_FORM_data8
22 .section .debug_info.dwo, "e", @progbits
24 .long .LCUEnd-.LCUVersion # Length of Unit
27 .long 0 # Abbrev offset
28 .byte 8 # Address size
29 .uleb128 1 # Abbrev [1] DW_TAG_compile_unit
30 .quad 0x1100001122222222 # DW_AT_GNU_dwo_id
33 .section .debug_types.dwo, "e", @progbits
36 .section .debug_cu_index, "", @progbits
39 .long 2 # Section count
42 ## Hash Table of Signatures:
43 .quad 0x1100001122222222
45 ## Parallel Table of Indexes:
48 ## Table of Section Offsets:
50 .long 1 # DW_SECT_INFO
51 .long 3 # DW_SECT_ABBREV
53 .long 0 # Offset in .debug_info.dwo
54 .long 0 # Offset in .debug_abbrev.dwo
55 ## Table of Section Sizes:
56 .long .LCUEnd-.LCUBegin # Size in .debug_info.dwo
57 .long .LAbbrevEnd-.LAbbrevBegin # Size in .debug_abbrev.dwo
59 .section .debug_tu_index, "", @progbits
63 .long 2 # Section count
66 ## Hash Table of Signatures:
67 .quad 0x1100003333333333
69 ## Parallel Table of Indexes:
72 ## Table of Section Offsets:
74 .long 1 # DW_SECT_INFO
75 .long 3 # DW_SECT_ABBREV
79 ## Table of Section Sizes: