1RUN: llvm-dwp %p/../Inputs/merge/notypes/c.dwo %p/../Inputs/merge/notypes/ab.dwp -o %t 2RUN: llvm-dwarfdump -v %t | FileCheck --check-prefix=CHECK --check-prefix=NOTYP %s 3 4FIXME: For some reason, piping straight from llvm-dwp to llvm-dwarfdump -v doesn't behave well - looks like dwarfdump is reading/closes before dwp has finished. 5 6DWP from a DWO (c.dwo) and a DWP (ab.dwp, created from a.dwo and b.dwo) 7Make sure the entries for A and B are updated correctly when read/processed from ab.dwp 8a.cpp: 9 struct foo { }; 10 foo a; 11 12b.cpp: 13 struct bar { }; 14 void b(bar) { 15 } 16 17c.cpp: 18 typedef int baz; 19 baz c() { 20 } 21 22CHECK-LABEL: .debug_abbrev.dwo contents: 23CHECK-LABEL: Abbrev table for offset: 24CHECK: 0x0000[[CAOFF:.*]] 25CHECK-LABEL: Abbrev table for offset: 26CHECK: 0x0000[[AAOFF:.*]] 27CHECK-LABEL: Abbrev table for offset: 28CHECK: 0x0000[[BAOFF:.*]] 29 30CHECK: .debug_info.dwo contents: 31CHECK: [[COFF:0x[0-9a-f]*]]: 32CHECK-LABEL: Compile Unit: length = {{.*}} version = 0x0004 abbr_offset = 33CHECK: 0x[[CAOFF]] addr_size = 0x08 (next unit at [[AOFF:.*]]) 34CHECK: DW_AT_GNU_dwo_id {{.*}} ([[DWOC:.*]]) 35CHECK: [[AOFF]]: 36CHECK-LABEL: Compile Unit: length = {{.*}} version = 0x0004 abbr_offset = 37CHECK: 0x[[AAOFF]] addr_size = 0x08 (next unit at [[BOFF:.*]]) 38CHECK: DW_AT_GNU_dwo_id {{.*}} ([[DWOA:.*]]) 39CHECK: [[BOFF]]: 40CHECK-LABEL: Compile Unit: length = {{.*}} version = 0x0004 abbr_offset = 41CHECK: 0x[[BAOFF]] addr_size = 0x08 (next unit at [[XOFF:.*]]) 42CHECK: DW_AT_GNU_dwo_id {{.*}} ([[DWOB:.*]]) 43 44CHECK-LABEL: .debug_cu_index 45CHECK: Index Signature INFO ABBREV LINE STR_OFFSETS 46CHECK-DAG: [[DWOC]] {{\[}}[[COFF]], [[AOFF]]) [0x0000[[CAOFF]], 0x0000[[AAOFF]]) [0x00000000, 0x00000011) [0x00000000, 0x00000018) 47CHECK-DAG: [[DWOA]] {{\[}}[[AOFF]], [[BOFF]]) [0x0000[[AAOFF]], 0x0000[[BAOFF]]) [0x00000011, 0x00000022) [0x00000018, 0x00000028) 48CHECK-DAG: [[DWOB]] {{\[}}[[BOFF]], [[XOFF]]) [0x0000[[BAOFF]], 0x000000c3) [0x00000022, 0x00000033) [0x00000028, 0x0000003c) 49