Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 1 | ; REQUIRES: object-emission |
| 2 | |
David Blaikie | 29459ae | 2014-07-25 17:11:58 +0000 | [diff] [blame] | 3 | ; RUN: llc < %s -o %t -filetype=obj -O0 -generate-type-units -mtriple=x86_64-unknown-linux-gnu |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 4 | ; RUN: llvm-dwarfdump %t | FileCheck --check-prefix=CHECK --check-prefix=SINGLE %s |
David Blaikie | c13bc97 | 2014-08-27 05:04:14 +0000 | [diff] [blame] | 5 | ; RUN: llvm-readobj -s -t %t | FileCheck --check-prefix=OBJ_SINGLE %s |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 6 | |
David Blaikie | 29459ae | 2014-07-25 17:11:58 +0000 | [diff] [blame] | 7 | ; RUN: llc < %s -split-dwarf=Enable -o %t -filetype=obj -O0 -generate-type-units -mtriple=x86_64-unknown-linux-gnu |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 8 | ; RUN: llvm-dwarfdump %t | FileCheck --check-prefix=CHECK --check-prefix=FISSION %s |
David Blaikie | c13bc97 | 2014-08-27 05:04:14 +0000 | [diff] [blame] | 9 | ; RUN: llvm-readobj -s -t %t | FileCheck --check-prefix=OBJ_FISSION %s |
David Blaikie | 8a263cb | 2013-11-26 00:22:37 +0000 | [diff] [blame] | 10 | |
David Blaikie | 5b85858 | 2014-02-12 00:40:47 +0000 | [diff] [blame] | 11 | ; Generated from bar.cpp: |
| 12 | |
| 13 | ; #line 1 "bar.h" |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 14 | ; struct bar {}; |
David Blaikie | 5b85858 | 2014-02-12 00:40:47 +0000 | [diff] [blame] | 15 | ; #line 2 "bar.cpp" |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 16 | |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 17 | ; struct bar b; |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 18 | |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 19 | ; void foo(void) { |
| 20 | ; struct baz {}; |
| 21 | ; baz b; |
| 22 | ; } |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 23 | |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 24 | ; namespace echidna { |
| 25 | ; namespace capybara { |
| 26 | ; namespace mongoose { |
| 27 | ; class fluffy { |
| 28 | ; int a; |
| 29 | ; int b; |
| 30 | ; }; |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 31 | |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 32 | ; fluffy animal; |
| 33 | ; } |
| 34 | ; } |
| 35 | ; } |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 36 | |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 37 | ; namespace { |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 38 | ; struct walrus { |
| 39 | ; walrus() {} |
| 40 | ; }; |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 41 | ; } |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 42 | |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 43 | ; walrus w; |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 44 | |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 45 | ; struct wombat { |
| 46 | ; struct { |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 47 | ; int a; |
| 48 | ; int b; |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 49 | ; } a_b; |
| 50 | ; }; |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 51 | |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 52 | ; wombat wom; |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 53 | |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 54 | ; SINGLE-LABEL: .debug_info contents: |
| 55 | ; FISSION-LABEL: .debug_info.dwo contents: |
Eric Christopher | c4dd56b | 2013-12-05 01:00:12 +0000 | [diff] [blame] | 56 | ; CHECK: Compile Unit: length = [[CU_SIZE:[0-9a-f]+]] |
David Blaikie | bc56327 | 2013-12-13 21:33:40 +0000 | [diff] [blame] | 57 | |
David Blaikie | c3d9e9e | 2014-03-06 01:42:00 +0000 | [diff] [blame] | 58 | ; CHECK: [[BAR:^0x........]]: DW_TAG_structure_type |
David Blaikie | 322d79b | 2014-01-31 19:52:26 +0000 | [diff] [blame] | 59 | ; CHECK-NEXT: DW_AT_declaration |
David Blaikie | c3d9e9e | 2014-03-06 01:42:00 +0000 | [diff] [blame] | 60 | ; CHECK-NEXT: DW_AT_signature {{.*}} (0x1d02f3be30cc5688) |
| 61 | ; CHECK: [[FLUFFY:^0x........]]: DW_TAG_class_type |
David Blaikie | 322d79b | 2014-01-31 19:52:26 +0000 | [diff] [blame] | 62 | ; CHECK-NEXT: DW_AT_declaration |
David Blaikie | c3d9e9e | 2014-03-06 01:42:00 +0000 | [diff] [blame] | 63 | ; CHECK-NEXT: DW_AT_signature {{.*}} (0xb04af47397402e77) |
David Blaikie | cfb2115 | 2014-01-03 18:59:42 +0000 | [diff] [blame] | 64 | |
| 65 | ; Ensure the CU-local type 'walrus' is not placed in a type unit. |
David Blaikie | c3d9e9e | 2014-03-06 01:42:00 +0000 | [diff] [blame] | 66 | ; CHECK: [[WALRUS:^0x........]]: DW_TAG_structure_type |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 67 | ; CHECK-NEXT: DW_AT_name{{.*}}"walrus" |
David Blaikie | cfb2115 | 2014-01-03 18:59:42 +0000 | [diff] [blame] | 68 | ; CHECK-NEXT: DW_AT_byte_size |
| 69 | ; CHECK-NEXT: DW_AT_decl_file |
| 70 | ; CHECK-NEXT: DW_AT_decl_line |
| 71 | |
David Blaikie | c3d9e9e | 2014-03-06 01:42:00 +0000 | [diff] [blame] | 72 | |
| 73 | ; CHECK: [[WOMBAT:^0x........]]: DW_TAG_structure_type |
| 74 | ; CHECK-NEXT: DW_AT_declaration |
| 75 | ; CHECK-NEXT: DW_AT_signature {{.*}} (0xfd756cee88f8a118) |
| 76 | |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 77 | ; SINGLE-LABEL: .debug_types contents: |
David Blaikie | c13bc97 | 2014-08-27 05:04:14 +0000 | [diff] [blame] | 78 | ; FISSION-NOT: .debug_types contents: |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 79 | ; FISSION-LABEL: .debug_types.dwo contents: |
David Blaikie | bc56327 | 2013-12-13 21:33:40 +0000 | [diff] [blame] | 80 | |
David Blaikie | 6201712 | 2013-12-13 01:24:54 +0000 | [diff] [blame] | 81 | ; Check that we generate a hash for bar and the value. |
David Blaikie | cfb2115 | 2014-01-03 18:59:42 +0000 | [diff] [blame] | 82 | ; CHECK-NOT: type_signature |
| 83 | ; CHECK-LABEL: type_signature = 0x1d02f3be30cc5688 |
David Blaikie | 6201712 | 2013-12-13 01:24:54 +0000 | [diff] [blame] | 84 | ; CHECK: DW_TAG_structure_type |
David Blaikie | 3a443c2 | 2014-11-04 22:12:25 +0000 | [diff] [blame] | 85 | ; FISSION-NEXT: DW_AT_name {{.*}} ( indexed {{.*}} "bar" |
| 86 | ; SINGLE-NEXT: DW_AT_name {{.*}} "bar" |
David Blaikie | 409dd9c | 2013-11-19 23:08:21 +0000 | [diff] [blame] | 87 | |
David Blaikie | bc56327 | 2013-12-13 21:33:40 +0000 | [diff] [blame] | 88 | |
David Blaikie | 409dd9c | 2013-11-19 23:08:21 +0000 | [diff] [blame] | 89 | ; Check that we generate a hash for fluffy and the value. |
David Blaikie | cfb2115 | 2014-01-03 18:59:42 +0000 | [diff] [blame] | 90 | ; CHECK-NOT: type_signature |
| 91 | ; CHECK-LABEL: type_signature = 0xb04af47397402e77 |
| 92 | ; CHECK-NOT: DW_AT_GNU_odr_signature [DW_FORM_data8] (0x9a0124d5a0c21c52) |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 93 | ; CHECK: DW_TAG_namespace |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 94 | ; CHECK-NEXT: DW_AT_name{{.*}}"echidna" |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 95 | ; CHECK: DW_TAG_namespace |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 96 | ; CHECK-NEXT: DW_AT_name{{.*}}"capybara" |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 97 | ; CHECK: DW_TAG_namespace |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 98 | ; CHECK-NEXT: DW_AT_name{{.*}}"mongoose" |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 99 | ; CHECK: DW_TAG_class_type |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 100 | ; CHECK-NEXT: DW_AT_name{{.*}}"fluffy" |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 101 | |
David Blaikie | 6201712 | 2013-12-13 01:24:54 +0000 | [diff] [blame] | 102 | ; Check that we generate a hash for wombat and the value, but not for the |
| 103 | ; anonymous type contained within. |
David Blaikie | cfb2115 | 2014-01-03 18:59:42 +0000 | [diff] [blame] | 104 | ; CHECK-NOT: type_signature |
| 105 | ; CHECK-LABEL: type_signature = 0xfd756cee88f8a118 |
| 106 | ; CHECK-NOT: DW_AT_GNU_odr_signature [DW_FORM_data8] (0x685bcc220141e9d7) |
David Blaikie | 6201712 | 2013-12-13 01:24:54 +0000 | [diff] [blame] | 107 | ; CHECK: DW_TAG_structure_type |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 108 | ; CHECK-NEXT: DW_AT_name{{.*}}"wombat" |
David Blaikie | bc56327 | 2013-12-13 21:33:40 +0000 | [diff] [blame] | 109 | |
David Blaikie | cfb2115 | 2014-01-03 18:59:42 +0000 | [diff] [blame] | 110 | ; CHECK-NOT: type_signature |
| 111 | ; CHECK-LABEL: type_signature = 0xe94f6d3843e62d6b |
David Blaikie | 6201712 | 2013-12-13 01:24:54 +0000 | [diff] [blame] | 112 | ; CHECK: DW_TAG_type_unit |
David Blaikie | 4a2f95f | 2014-03-18 01:17:26 +0000 | [diff] [blame] | 113 | ; CHECK: DW_AT_stmt_list [DW_FORM_sec_offset] (0x00000000) |
David Blaikie | bc56327 | 2013-12-13 21:33:40 +0000 | [diff] [blame] | 114 | ; CHECK-NOT: NULL |
David Blaikie | bc56327 | 2013-12-13 21:33:40 +0000 | [diff] [blame] | 115 | ; CHECK-NOT: DW_AT_GNU_odr_signature |
David Blaikie | 6201712 | 2013-12-13 01:24:54 +0000 | [diff] [blame] | 116 | ; CHECK: DW_TAG_structure_type |
David Blaikie | bc56327 | 2013-12-13 21:33:40 +0000 | [diff] [blame] | 117 | ; The signature for the outer 'wombat' type |
David Blaikie | cfb2115 | 2014-01-03 18:59:42 +0000 | [diff] [blame] | 118 | ; CHECK: DW_AT_signature [DW_FORM_ref_sig8] (0xfd756cee88f8a118) |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 119 | ; CHECK: DW_TAG_structure_type |
David Blaikie | 409dd9c | 2013-11-19 23:08:21 +0000 | [diff] [blame] | 120 | ; CHECK-NOT: DW_AT_name |
| 121 | ; CHECK-NOT: DW_AT_GNU_odr_signature |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 122 | ; CHECK: DW_TAG_member |
David Blaikie | 15ed5eb | 2014-01-10 01:38:41 +0000 | [diff] [blame] | 123 | ; CHECK-NEXT: DW_AT_name{{.*}}"a" |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 124 | |
David Blaikie | 9acebfd | 2014-02-14 19:51:35 +0000 | [diff] [blame] | 125 | ; CHECK-LABEL: .debug_line contents: |
| 126 | ; CHECK: Line table prologue |
| 127 | ; CHECK-NOT: file_names[ |
David Blaikie | 4a2f95f | 2014-03-18 01:17:26 +0000 | [diff] [blame] | 128 | ; SINGLE: file_names{{.*}} bar.h |
David Blaikie | 9acebfd | 2014-02-14 19:51:35 +0000 | [diff] [blame] | 129 | ; CHECK: file_names{{.*}} bar.cpp |
| 130 | ; CHECK-NOT: file_names[ |
David Blaikie | 4a2f95f | 2014-03-18 01:17:26 +0000 | [diff] [blame] | 131 | |
| 132 | ; CHECK-LABEL: .debug_line.dwo contents: |
| 133 | ; FISSION: Line table prologue |
David Blaikie | 8287aff | 2014-03-18 02:13:23 +0000 | [diff] [blame] | 134 | ; FISSION: opcode_base: 1 |
| 135 | ; FISSION-NOT: standard_opcode_lengths |
David Blaikie | 47f4b82 | 2014-03-19 00:11:28 +0000 | [diff] [blame] | 136 | ; FISSION-NOT: include_directories |
David Blaikie | 4a2f95f | 2014-03-18 01:17:26 +0000 | [diff] [blame] | 137 | ; FISSION-NOT: file_names[ |
| 138 | ; FISSION: file_names{{.*}} bar.h |
| 139 | ; FISSION: file_names{{.*}} bar.cpp |
| 140 | ; FISSION-NOT: file_names[ |
| 141 | |
David Blaikie | 9acebfd | 2014-02-14 19:51:35 +0000 | [diff] [blame] | 142 | ; CHECK-LABEL: .debug_str contents: |
| 143 | |
David Blaikie | fd1eff5 | 2013-11-26 19:14:34 +0000 | [diff] [blame] | 144 | ; Use the unit size as a rough hash/identifier for the unit we're dealing with |
| 145 | ; it happens to be unambiguous at the moment, but it's hardly ideal. |
David Blaikie | 8a263cb | 2013-11-26 00:22:37 +0000 | [diff] [blame] | 146 | ; CHECK-LABEL: .debug_pubtypes contents: |
David Blaikie | fd1eff5 | 2013-11-26 19:14:34 +0000 | [diff] [blame] | 147 | ; Don't emit pubtype entries for type DIEs in the compile unit that just indirect to a type unit. |
Eric Christopher | c4dd56b | 2013-12-05 01:00:12 +0000 | [diff] [blame] | 148 | ; CHECK-NEXT: unit_size = [[CU_SIZE]] |
David Blaikie | fd1eff5 | 2013-11-26 19:14:34 +0000 | [diff] [blame] | 149 | ; CHECK-NEXT: Offset Name |
David Blaikie | 553eb4a | 2014-06-06 22:16:56 +0000 | [diff] [blame] | 150 | ; CHECK-DAG: [[BAR]] "bar" |
| 151 | ; CHECK-DAG: [[WALRUS]] "(anonymous namespace)::walrus" |
| 152 | ; CHECK-DAG: [[WOMBAT]] "wombat" |
| 153 | ; CHECK-DAG: [[FLUFFY]] "echidna::capybara::mongoose::fluffy" |
David Blaikie | 8a263cb | 2013-11-26 00:22:37 +0000 | [diff] [blame] | 154 | |
David Blaikie | 29459ae | 2014-07-25 17:11:58 +0000 | [diff] [blame] | 155 | ; Make sure debug_types are in comdat groups. This could be more rigid to check |
| 156 | ; that they're the right comdat groups (each type in a separate comdat group, |
| 157 | ; etc) |
David Blaikie | c13bc97 | 2014-08-27 05:04:14 +0000 | [diff] [blame] | 158 | ; OBJ_SINGLE: Name: .debug_types ( |
| 159 | ; OBJ_SINGLE-NOT: } |
| 160 | ; OBJ_SINGLE: SHF_GROUP |
David Blaikie | 29459ae | 2014-07-25 17:11:58 +0000 | [diff] [blame] | 161 | |
| 162 | ; Fission type units don't go in comdat groups, since their linker is debug |
| 163 | ; aware it's handled using the debug info semantics rather than raw ELF object |
| 164 | ; semantics. |
| 165 | ; OBJ_FISSION: Name: .debug_types.dwo ( |
| 166 | ; OBJ_FISSION-NOT: SHF_GROUP |
| 167 | ; OBJ_FISSION: } |
| 168 | |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 169 | %struct.bar = type { i8 } |
| 170 | %"class.echidna::capybara::mongoose::fluffy" = type { i32, i32 } |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 171 | %"struct.<anonymous namespace>::walrus" = type { i8 } |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 172 | %struct.wombat = type { %struct.anon } |
| 173 | %struct.anon = type { i32, i32 } |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 174 | %struct.baz = type { i8 } |
| 175 | |
| 176 | @b = global %struct.bar zeroinitializer, align 1 |
| 177 | @_ZN7echidna8capybara8mongoose6animalE = global %"class.echidna::capybara::mongoose::fluffy" zeroinitializer, align 4 |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 178 | @w = internal global %"struct.<anonymous namespace>::walrus" zeroinitializer, align 1 |
Eric Christopher | d853ea3 | 2013-07-29 23:53:05 +0000 | [diff] [blame] | 179 | @wom = global %struct.wombat zeroinitializer, align 4 |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 180 | @llvm.global_ctors = appending global [1 x { i32, void ()* }] [{ i32, void ()* } { i32 65535, void ()* @_GLOBAL__I_a }] |
| 181 | |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 182 | ; Function Attrs: nounwind uwtable |
Peter Collingbourne | d4bff30 | 2015-11-05 22:03:56 +0000 | [diff] [blame] | 183 | define void @_Z3foov() #0 !dbg !22 { |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 184 | entry: |
| 185 | %b = alloca %struct.baz, align 1 |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 186 | call void @llvm.dbg.declare(metadata %struct.baz* %b, metadata !46, metadata !DIExpression()), !dbg !48 |
David Blaikie | 5b85858 | 2014-02-12 00:40:47 +0000 | [diff] [blame] | 187 | ret void, !dbg !49 |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 188 | } |
| 189 | |
| 190 | ; Function Attrs: nounwind readnone |
Adrian Prantl | 87b7eb9 | 2014-10-01 18:55:02 +0000 | [diff] [blame] | 191 | declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 192 | |
Peter Collingbourne | d4bff30 | 2015-11-05 22:03:56 +0000 | [diff] [blame] | 193 | define internal void @__cxx_global_var_init() section ".text.startup" !dbg !26 { |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 194 | entry: |
David Blaikie | 5b85858 | 2014-02-12 00:40:47 +0000 | [diff] [blame] | 195 | call void @_ZN12_GLOBAL__N_16walrusC2Ev(%"struct.<anonymous namespace>::walrus"* @w), !dbg !50 |
| 196 | ret void, !dbg !50 |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 197 | } |
| 198 | |
| 199 | ; Function Attrs: nounwind uwtable |
Peter Collingbourne | d4bff30 | 2015-11-05 22:03:56 +0000 | [diff] [blame] | 200 | define internal void @_ZN12_GLOBAL__N_16walrusC2Ev(%"struct.<anonymous namespace>::walrus"* %this) unnamed_addr #0 align 2 !dbg !27 { |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 201 | entry: |
| 202 | %this.addr = alloca %"struct.<anonymous namespace>::walrus"*, align 8 |
| 203 | store %"struct.<anonymous namespace>::walrus"* %this, %"struct.<anonymous namespace>::walrus"** %this.addr, align 8 |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 204 | call void @llvm.dbg.declare(metadata %"struct.<anonymous namespace>::walrus"** %this.addr, metadata !51, metadata !DIExpression()), !dbg !53 |
David Blaikie | a79ac14 | 2015-02-27 21:17:42 +0000 | [diff] [blame] | 205 | %this1 = load %"struct.<anonymous namespace>::walrus"*, %"struct.<anonymous namespace>::walrus"** %this.addr |
David Blaikie | 5b85858 | 2014-02-12 00:40:47 +0000 | [diff] [blame] | 206 | ret void, !dbg !54 |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 207 | } |
| 208 | |
Peter Collingbourne | d4bff30 | 2015-11-05 22:03:56 +0000 | [diff] [blame] | 209 | define internal void @_GLOBAL__I_a() section ".text.startup" !dbg !36 { |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 210 | entry: |
David Blaikie | 5b85858 | 2014-02-12 00:40:47 +0000 | [diff] [blame] | 211 | call void @__cxx_global_var_init(), !dbg !55 |
| 212 | ret void, !dbg !55 |
Eric Christopher | e414ece | 2013-07-29 23:53:08 +0000 | [diff] [blame] | 213 | } |
| 214 | |
David Blaikie | ba8125d | 2013-11-01 22:29:28 +0000 | [diff] [blame] | 215 | attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "no-frame-pointer-elim-non-leaf" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "stack-protector-buffer-size"="8" "unsafe-fp-math"="false" "use-soft-float"="false" } |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 216 | attributes #1 = { nounwind readnone } |
| 217 | |
| 218 | !llvm.dbg.cu = !{!0} |
David Blaikie | 5b85858 | 2014-02-12 00:40:47 +0000 | [diff] [blame] | 219 | !llvm.module.flags = !{!43, !44} |
| 220 | !llvm.ident = !{!45} |
Eric Christopher | 6764643 | 2013-07-26 17:02:41 +0000 | [diff] [blame] | 221 | |
Adrian Prantl | 75819ae | 2016-04-15 15:57:41 +0000 | [diff] [blame^] | 222 | !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.5 ", isOptimized: false, splitDebugFilename: "bar.dwo", emissionKind: FullDebug, file: !1, enums: !2, retainedTypes: !3, globals: !38, imports: !2) |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 223 | !1 = !DIFile(filename: "bar.cpp", directory: "/tmp/dbginfo") |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 224 | !2 = !{} |
| 225 | !3 = !{!4, !6, !14, !17} |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 226 | !4 = !DICompositeType(tag: DW_TAG_structure_type, name: "bar", line: 1, size: 8, align: 8, file: !5, elements: !2, identifier: "_ZTS3bar") |
| 227 | !5 = !DIFile(filename: "bar.h", directory: "/tmp/dbginfo") |
| 228 | !6 = !DICompositeType(tag: DW_TAG_class_type, name: "fluffy", line: 13, size: 64, align: 32, file: !1, scope: !7, elements: !10, identifier: "_ZTSN7echidna8capybara8mongoose6fluffyE") |
| 229 | !7 = !DINamespace(name: "mongoose", line: 12, file: !1, scope: !8) |
| 230 | !8 = !DINamespace(name: "capybara", line: 11, file: !1, scope: !9) |
| 231 | !9 = !DINamespace(name: "echidna", line: 10, file: !1, scope: null) |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 232 | !10 = !{!11, !13} |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 233 | !11 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 14, size: 32, align: 32, flags: DIFlagPrivate, file: !1, scope: !"_ZTSN7echidna8capybara8mongoose6fluffyE", baseType: !12) |
| 234 | !12 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) |
| 235 | !13 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 15, size: 32, align: 32, offset: 32, flags: DIFlagPrivate, file: !1, scope: !"_ZTSN7echidna8capybara8mongoose6fluffyE", baseType: !12) |
| 236 | !14 = !DICompositeType(tag: DW_TAG_structure_type, name: "wombat", line: 31, size: 64, align: 32, file: !1, elements: !15, identifier: "_ZTS6wombat") |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 237 | !15 = !{!16} |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 238 | !16 = !DIDerivedType(tag: DW_TAG_member, name: "a_b", line: 35, size: 64, align: 32, file: !1, scope: !"_ZTS6wombat", baseType: !"_ZTSN6wombatUt_E") |
| 239 | !17 = !DICompositeType(tag: DW_TAG_structure_type, line: 32, size: 64, align: 32, file: !1, scope: !"_ZTS6wombat", elements: !18, identifier: "_ZTSN6wombatUt_E") |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 240 | !18 = !{!19, !20} |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 241 | !19 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 33, size: 32, align: 32, file: !1, scope: !"_ZTSN6wombatUt_E", baseType: !12) |
| 242 | !20 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 34, size: 32, align: 32, offset: 32, file: !1, scope: !"_ZTSN6wombatUt_E", baseType: !12) |
Adrian Prantl | 75819ae | 2016-04-15 15:57:41 +0000 | [diff] [blame^] | 243 | !22 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 5, file: !1, scope: !23, type: !24, variables: !2) |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 244 | !23 = !DIFile(filename: "bar.cpp", directory: "/tmp/dbginfo") |
| 245 | !24 = !DISubroutineType(types: !25) |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 246 | !25 = !{null} |
Adrian Prantl | 75819ae | 2016-04-15 15:57:41 +0000 | [diff] [blame^] | 247 | !26 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 29, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 29, file: !1, scope: !23, type: !24, variables: !2) |
| 248 | !27 = distinct !DISubprogram(name: "walrus", linkageName: "_ZN12_GLOBAL__N_16walrusC2Ev", line: 25, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 25, file: !1, scope: !28, type: !32, declaration: !31, variables: !2) |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 249 | !28 = !DICompositeType(tag: DW_TAG_structure_type, name: "walrus", line: 24, size: 8, align: 8, file: !1, scope: !29, elements: !30) |
| 250 | !29 = !DINamespace(line: 23, file: !1, scope: null) |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 251 | !30 = !{!31} |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 252 | !31 = !DISubprogram(name: "walrus", line: 25, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 25, file: !1, scope: !28, type: !32) |
| 253 | !32 = !DISubroutineType(types: !33) |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 254 | !33 = !{null, !34} |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 255 | !34 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !28) |
Adrian Prantl | 75819ae | 2016-04-15 15:57:41 +0000 | [diff] [blame^] | 256 | !36 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__I_a", line: 25, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial, isOptimized: false, unit: !0, scopeLine: 25, file: !1, scope: !23, type: !37, variables: !2) |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 257 | !37 = !DISubroutineType(types: !2) |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 258 | !38 = !{!39, !40, !41, !42} |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 259 | !39 = !DIGlobalVariable(name: "b", line: 3, isLocal: false, isDefinition: true, scope: null, file: !23, type: !4, variable: %struct.bar* @b) |
| 260 | !40 = !DIGlobalVariable(name: "animal", linkageName: "_ZN7echidna8capybara8mongoose6animalE", line: 18, isLocal: false, isDefinition: true, scope: !7, file: !23, type: !6, variable: %"class.echidna::capybara::mongoose::fluffy"* @_ZN7echidna8capybara8mongoose6animalE) |
| 261 | !41 = !DIGlobalVariable(name: "w", line: 29, isLocal: true, isDefinition: true, scope: null, file: !23, type: !28, variable: %"struct.<anonymous namespace>::walrus"* @w) |
| 262 | !42 = !DIGlobalVariable(name: "wom", line: 38, isLocal: false, isDefinition: true, scope: null, file: !23, type: !14, variable: %struct.wombat* @wom) |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 263 | !43 = !{i32 2, !"Dwarf Version", i32 4} |
Duncan P. N. Exon Smith | e274180 | 2015-03-03 17:24:31 +0000 | [diff] [blame] | 264 | !44 = !{i32 1, !"Debug Info Version", i32 3} |
Duncan P. N. Exon Smith | be7ea19 | 2014-12-15 19:07:53 +0000 | [diff] [blame] | 265 | !45 = !{!"clang version 3.5 "} |
Duncan P. N. Exon Smith | ed013cd | 2015-07-31 18:58:39 +0000 | [diff] [blame] | 266 | !46 = !DILocalVariable(name: "b", line: 7, scope: !22, file: !23, type: !47) |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 267 | !47 = !DICompositeType(tag: DW_TAG_structure_type, name: "baz", line: 6, size: 8, align: 8, file: !1, scope: !22, elements: !2) |
| 268 | !48 = !DILocation(line: 7, scope: !22) |
| 269 | !49 = !DILocation(line: 8, scope: !22) |
| 270 | !50 = !DILocation(line: 29, scope: !26) |
Duncan P. N. Exon Smith | ed013cd | 2015-07-31 18:58:39 +0000 | [diff] [blame] | 271 | !51 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !27, type: !52) |
Duncan P. N. Exon Smith | a9308c4 | 2015-04-29 16:38:44 +0000 | [diff] [blame] | 272 | !52 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !28) |
| 273 | !53 = !DILocation(line: 0, scope: !27) |
| 274 | !54 = !DILocation(line: 25, scope: !27) |
| 275 | !55 = !DILocation(line: 25, scope: !36) |