mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Add Destroy.SubobjectDestroy as a temporary replacement for Destroy.Op (#7773)
This change partially implements [PR #7362], which revises how objects are destroyed. It is a partial implementation for two reasons: 1. This change moves `Destroy.Op`'s current behaviour into `Destroy.SubobjectDestroy`, but it doesn't add support for objects with non-trivial destruction. 2. `Destroy.SubobjectDestroy` is a workaround for `require impls SubobjectDestroy`. We aren't able to use the latter until the dependents add their requirements' implementations to their own witness tables. [PR #7362]: https://github.com/carbon-language/carbon-lang/pulls/7362
This commit is contained in:
+243
-103
@@ -185,7 +185,7 @@ fn G() {
|
||||
// CHECK:STDOUT: define internal void @_ZN6CarbonL11CallLayoutAEPNS_7LayoutAE(ptr noundef %0) #2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !108
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !144
|
||||
// CHECK:STDOUT: call void @_CCallLayoutA__carbon_thunk.Main(ptr noundef nonnull align 8 dereferenceable(8) %.addr)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
@@ -194,7 +194,7 @@ fn G() {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN6Carbon7LayoutAD2Ev(ptr noundef nonnull align 8 dead_on_return(12) dereferenceable(12) %this) unnamed_addr #3 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !108
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !144
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @"_C__destroy_thunk:thunk.LayoutA.Main"(ptr noundef nonnull align 8 dereferenceable(12) %this1)
|
||||
// CHECK:STDOUT: ret void
|
||||
@@ -218,7 +218,7 @@ fn G() {
|
||||
// CHECK:STDOUT: define internal void @_ZN6CarbonL11CallLayoutBEPNS_7LayoutBE(ptr noundef %0) #2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !146
|
||||
// CHECK:STDOUT: call void @_CCallLayoutB__carbon_thunk.Main(ptr noundef nonnull align 8 dereferenceable(8) %.addr)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
@@ -227,7 +227,7 @@ fn G() {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN6Carbon7LayoutBD2Ev(ptr noundef nonnull align 8 dead_on_return(16) dereferenceable(16) %this) unnamed_addr #3 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !146
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @"_C__destroy_thunk:thunk.LayoutB.Main"(ptr noundef nonnull align 8 dereferenceable(16) %this1)
|
||||
// CHECK:STDOUT: %a = getelementptr inbounds nuw %"class.Carbon::LayoutB", ptr %this1, i32 0, i32 0
|
||||
@@ -251,7 +251,7 @@ fn G() {
|
||||
// CHECK:STDOUT: define internal void @_ZN6CarbonL11CallLayoutCEPNS_7LayoutCE(ptr noundef %0) #2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !112
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !148
|
||||
// CHECK:STDOUT: call void @_CCallLayoutC__carbon_thunk.Main(ptr noundef nonnull align 8 dereferenceable(8) %.addr)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
@@ -260,7 +260,7 @@ fn G() {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN6Carbon7LayoutCD2Ev(ptr noundef nonnull align 8 dead_on_return(16) dereferenceable(16) %this) unnamed_addr #3 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !112
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !148
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @"_C__destroy_thunk:thunk.LayoutC.Main"(ptr noundef nonnull align 8 dereferenceable(16) %this1)
|
||||
// CHECK:STDOUT: call void @_ZN6Carbon7LayoutAD2Ev(ptr noundef nonnull align 8 dead_on_return(12) dereferenceable(12) %this1) #5
|
||||
@@ -276,90 +276,151 @@ fn G() {
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.LayoutA.Main"(ptr %self) #4 !dbg !55 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.5a318796badc8ab7:core.Destroy.Core"(ptr %self), !dbg !57
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.5a318796badc8ab7:core.Destroy.Core"(ptr %self), !dbg !57
|
||||
// CHECK:STDOUT: ret void, !dbg !57
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.f58524831c37807e:core.Destroy.Core"(ptr %self) #5 !dbg !59 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.d088c7eb746488be:core.Destroy.Core"(ptr %self) #5 !dbg !59 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !61
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.63f0d36eb067b612:core.Destroy.Core"(ptr %self) #5 !dbg !63 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.6dae29ece9a708c4:core.Destroy.Core"(ptr %self) #5 !dbg !63 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !65
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.5a318796badc8ab7:core.Destroy.Core"(ptr %self) #5 !dbg !67 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core"(ptr %self) #5 !dbg !67 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !69
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CCallLayoutA__carbon_thunk.Main(ptr %_) #5 !dbg !71 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.f58524831c37807e:core.Destroy.Core"(ptr %self) #5 !dbg !71 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc21 = load ptr, ptr %_, align 8, !dbg !73
|
||||
// CHECK:STDOUT: call void @_CCallLayoutA.Main(ptr %.loc21), !dbg !73
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core"(ptr %self), !dbg !73
|
||||
// CHECK:STDOUT: ret void, !dbg !73
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.LayoutB.Main"(ptr %self) #4 !dbg !75 {
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.63f0d36eb067b612:core.Destroy.Core"(ptr %self) #5 !dbg !75 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.98b9397038fd95a2:core.Destroy.Core"(ptr %self), !dbg !77
|
||||
// CHECK:STDOUT: ret void, !dbg !77
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.680fc8e588bd03e0:core.Destroy.Core"(ptr %self) #5 !dbg !79 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.63f0d36eb067b612:core.Destroy.Core"(ptr %self) #5 !dbg !79 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.63f0d36eb067b612:core.Destroy.Core"(ptr %self), !dbg !81
|
||||
// CHECK:STDOUT: ret void, !dbg !81
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.98b9397038fd95a2:core.Destroy.Core"(ptr %self) #5 !dbg !83 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.5a318796badc8ab7:core.Destroy.Core"(ptr %self) #5 !dbg !83 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !85
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CCallLayoutB__carbon_thunk.Main(ptr %_) #5 !dbg !87 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.5a318796badc8ab7:core.Destroy.Core"(ptr %self) #5 !dbg !87 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc22 = load ptr, ptr %_, align 8, !dbg !89
|
||||
// CHECK:STDOUT: call void @_CCallLayoutB.Main(ptr %.loc22), !dbg !89
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.5a318796badc8ab7:core.Destroy.Core"(ptr %self), !dbg !89
|
||||
// CHECK:STDOUT: ret void, !dbg !89
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.LayoutC.Main"(ptr %self) #4 !dbg !91 {
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CCallLayoutA__carbon_thunk.Main(ptr %_) #5 !dbg !91 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.bb6bd82e06513595:core.Destroy.Core"(ptr %self), !dbg !93
|
||||
// CHECK:STDOUT: %.loc21 = load ptr, ptr %_, align 8, !dbg !93
|
||||
// CHECK:STDOUT: call void @_CCallLayoutA.Main(ptr %.loc21), !dbg !93
|
||||
// CHECK:STDOUT: ret void, !dbg !93
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.d1ce4198d9e72e02:core.Destroy.Core"(ptr %self) #5 !dbg !95 {
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.LayoutB.Main"(ptr %self) #4 !dbg !95 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.98b9397038fd95a2:core.Destroy.Core"(ptr %self), !dbg !97
|
||||
// CHECK:STDOUT: ret void, !dbg !97
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.bb6bd82e06513595:core.Destroy.Core"(ptr %self) #5 !dbg !99 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.680fc8e588bd03e0:core.Destroy.Core"(ptr %self) #5 !dbg !99 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !101
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CCallLayoutC__carbon_thunk.Main(ptr %_) #5 !dbg !103 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.680fc8e588bd03e0:core.Destroy.Core"(ptr %self) #5 !dbg !103 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc23 = load ptr, ptr %_, align 8, !dbg !105
|
||||
// CHECK:STDOUT: call void @_CCallLayoutC.Main(ptr %.loc23), !dbg !105
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.680fc8e588bd03e0:core.Destroy.Core"(ptr %self), !dbg !105
|
||||
// CHECK:STDOUT: ret void, !dbg !105
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.98b9397038fd95a2:core.Destroy.Core"(ptr %self) #5 !dbg !107 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !109
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.98b9397038fd95a2:core.Destroy.Core"(ptr %self) #5 !dbg !111 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.98b9397038fd95a2:core.Destroy.Core"(ptr %self), !dbg !113
|
||||
// CHECK:STDOUT: ret void, !dbg !113
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CCallLayoutB__carbon_thunk.Main(ptr %_) #5 !dbg !115 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc22 = load ptr, ptr %_, align 8, !dbg !117
|
||||
// CHECK:STDOUT: call void @_CCallLayoutB.Main(ptr %.loc22), !dbg !117
|
||||
// CHECK:STDOUT: ret void, !dbg !117
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.LayoutC.Main"(ptr %self) #4 !dbg !119 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.bb6bd82e06513595:core.Destroy.Core"(ptr %self), !dbg !121
|
||||
// CHECK:STDOUT: ret void, !dbg !121
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.d1ce4198d9e72e02:core.Destroy.Core"(ptr %self) #5 !dbg !123 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !125
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.d1ce4198d9e72e02:core.Destroy.Core"(ptr %self) #5 !dbg !127 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.d1ce4198d9e72e02:core.Destroy.Core"(ptr %self), !dbg !129
|
||||
// CHECK:STDOUT: ret void, !dbg !129
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.bb6bd82e06513595:core.Destroy.Core"(ptr %self) #5 !dbg !131 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !133
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.bb6bd82e06513595:core.Destroy.Core"(ptr %self) #5 !dbg !135 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.bb6bd82e06513595:core.Destroy.Core"(ptr %self), !dbg !137
|
||||
// CHECK:STDOUT: ret void, !dbg !137
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CCallLayoutC__carbon_thunk.Main(ptr %_) #5 !dbg !139 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc23 = load ptr, ptr %_, align 8, !dbg !141
|
||||
// CHECK:STDOUT: call void @_CCallLayoutC.Main(ptr %.loc23), !dbg !141
|
||||
// CHECK:STDOUT: ret void, !dbg !141
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; uselistorder directives
|
||||
// CHECK:STDOUT: uselistorder ptr @_ZN6Carbon7LayoutAD2Ev, { 2, 1, 0 }
|
||||
// CHECK:STDOUT:
|
||||
@@ -397,60 +458,96 @@ fn G() {
|
||||
// CHECK:STDOUT: !56 = !DILocalVariable(arg: 1, scope: !55, type: !50)
|
||||
// CHECK:STDOUT: !57 = !DILocation(line: 6, column: 1, scope: !55)
|
||||
// CHECK:STDOUT: !58 = !{!56}
|
||||
// CHECK:STDOUT: !59 = distinct !DISubprogram(name: "Op", linkageName: "_COp.f58524831c37807e:core.Destroy.Core", scope: null, file: !48, line: 6, type: !54, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !62)
|
||||
// CHECK:STDOUT: !60 = !DILocalVariable(arg: 1, scope: !59, type: !37)
|
||||
// CHECK:STDOUT: !59 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.d088c7eb746488be:core.Destroy.Core", scope: null, file: !48, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !62)
|
||||
// CHECK:STDOUT: !60 = !DILocalVariable(arg: 1, scope: !59, type: !50)
|
||||
// CHECK:STDOUT: !61 = !DILocation(line: 6, column: 1, scope: !59)
|
||||
// CHECK:STDOUT: !62 = !{!60}
|
||||
// CHECK:STDOUT: !63 = distinct !DISubprogram(name: "Op", linkageName: "_COp.63f0d36eb067b612:core.Destroy.Core", scope: null, file: !48, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !66)
|
||||
// CHECK:STDOUT: !64 = !DILocalVariable(arg: 1, scope: !63, type: !50)
|
||||
// CHECK:STDOUT: !63 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.6dae29ece9a708c4:core.Destroy.Core", scope: null, file: !48, line: 6, type: !54, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !66)
|
||||
// CHECK:STDOUT: !64 = !DILocalVariable(arg: 1, scope: !63, type: !37)
|
||||
// CHECK:STDOUT: !65 = !DILocation(line: 6, column: 1, scope: !63)
|
||||
// CHECK:STDOUT: !66 = !{!64}
|
||||
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5a318796badc8ab7:core.Destroy.Core", scope: null, file: !48, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !70)
|
||||
// CHECK:STDOUT: !68 = !DILocalVariable(arg: 1, scope: !67, type: !50)
|
||||
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core", scope: null, file: !48, line: 6, type: !54, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !70)
|
||||
// CHECK:STDOUT: !68 = !DILocalVariable(arg: 1, scope: !67, type: !37)
|
||||
// CHECK:STDOUT: !69 = !DILocation(line: 6, column: 1, scope: !67)
|
||||
// CHECK:STDOUT: !70 = !{!68}
|
||||
// CHECK:STDOUT: !71 = distinct !DISubprogram(name: "CallLayoutA__carbon_thunk", linkageName: "_CCallLayoutA__carbon_thunk.Main", scope: null, file: !48, line: 21, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !74)
|
||||
// CHECK:STDOUT: !72 = !DILocalVariable(arg: 1, scope: !71, type: !50)
|
||||
// CHECK:STDOUT: !73 = !DILocation(line: 21, column: 1, scope: !71)
|
||||
// CHECK:STDOUT: !71 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.f58524831c37807e:core.Destroy.Core", scope: null, file: !48, line: 6, type: !54, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !74)
|
||||
// CHECK:STDOUT: !72 = !DILocalVariable(arg: 1, scope: !71, type: !37)
|
||||
// CHECK:STDOUT: !73 = !DILocation(line: 6, column: 1, scope: !71)
|
||||
// CHECK:STDOUT: !74 = !{!72}
|
||||
// CHECK:STDOUT: !75 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.LayoutB.Main", scope: null, file: !48, line: 11, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !78)
|
||||
// CHECK:STDOUT: !75 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.63f0d36eb067b612:core.Destroy.Core", scope: null, file: !48, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !78)
|
||||
// CHECK:STDOUT: !76 = !DILocalVariable(arg: 1, scope: !75, type: !50)
|
||||
// CHECK:STDOUT: !77 = !DILocation(line: 11, column: 1, scope: !75)
|
||||
// CHECK:STDOUT: !77 = !DILocation(line: 6, column: 1, scope: !75)
|
||||
// CHECK:STDOUT: !78 = !{!76}
|
||||
// CHECK:STDOUT: !79 = distinct !DISubprogram(name: "Op", linkageName: "_COp.680fc8e588bd03e0:core.Destroy.Core", scope: null, file: !48, line: 11, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !82)
|
||||
// CHECK:STDOUT: !79 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.63f0d36eb067b612:core.Destroy.Core", scope: null, file: !48, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !82)
|
||||
// CHECK:STDOUT: !80 = !DILocalVariable(arg: 1, scope: !79, type: !50)
|
||||
// CHECK:STDOUT: !81 = !DILocation(line: 11, column: 1, scope: !79)
|
||||
// CHECK:STDOUT: !81 = !DILocation(line: 6, column: 1, scope: !79)
|
||||
// CHECK:STDOUT: !82 = !{!80}
|
||||
// CHECK:STDOUT: !83 = distinct !DISubprogram(name: "Op", linkageName: "_COp.98b9397038fd95a2:core.Destroy.Core", scope: null, file: !48, line: 11, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !86)
|
||||
// CHECK:STDOUT: !83 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.5a318796badc8ab7:core.Destroy.Core", scope: null, file: !48, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !86)
|
||||
// CHECK:STDOUT: !84 = !DILocalVariable(arg: 1, scope: !83, type: !50)
|
||||
// CHECK:STDOUT: !85 = !DILocation(line: 11, column: 1, scope: !83)
|
||||
// CHECK:STDOUT: !85 = !DILocation(line: 6, column: 1, scope: !83)
|
||||
// CHECK:STDOUT: !86 = !{!84}
|
||||
// CHECK:STDOUT: !87 = distinct !DISubprogram(name: "CallLayoutB__carbon_thunk", linkageName: "_CCallLayoutB__carbon_thunk.Main", scope: null, file: !48, line: 22, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !90)
|
||||
// CHECK:STDOUT: !87 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.5a318796badc8ab7:core.Destroy.Core", scope: null, file: !48, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !90)
|
||||
// CHECK:STDOUT: !88 = !DILocalVariable(arg: 1, scope: !87, type: !50)
|
||||
// CHECK:STDOUT: !89 = !DILocation(line: 22, column: 1, scope: !87)
|
||||
// CHECK:STDOUT: !89 = !DILocation(line: 6, column: 1, scope: !87)
|
||||
// CHECK:STDOUT: !90 = !{!88}
|
||||
// CHECK:STDOUT: !91 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.LayoutC.Main", scope: null, file: !48, line: 16, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !94)
|
||||
// CHECK:STDOUT: !91 = distinct !DISubprogram(name: "CallLayoutA__carbon_thunk", linkageName: "_CCallLayoutA__carbon_thunk.Main", scope: null, file: !48, line: 21, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !94)
|
||||
// CHECK:STDOUT: !92 = !DILocalVariable(arg: 1, scope: !91, type: !50)
|
||||
// CHECK:STDOUT: !93 = !DILocation(line: 16, column: 1, scope: !91)
|
||||
// CHECK:STDOUT: !93 = !DILocation(line: 21, column: 1, scope: !91)
|
||||
// CHECK:STDOUT: !94 = !{!92}
|
||||
// CHECK:STDOUT: !95 = distinct !DISubprogram(name: "Op", linkageName: "_COp.d1ce4198d9e72e02:core.Destroy.Core", scope: null, file: !48, line: 16, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !98)
|
||||
// CHECK:STDOUT: !95 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.LayoutB.Main", scope: null, file: !48, line: 11, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !98)
|
||||
// CHECK:STDOUT: !96 = !DILocalVariable(arg: 1, scope: !95, type: !50)
|
||||
// CHECK:STDOUT: !97 = !DILocation(line: 16, column: 1, scope: !95)
|
||||
// CHECK:STDOUT: !97 = !DILocation(line: 11, column: 1, scope: !95)
|
||||
// CHECK:STDOUT: !98 = !{!96}
|
||||
// CHECK:STDOUT: !99 = distinct !DISubprogram(name: "Op", linkageName: "_COp.bb6bd82e06513595:core.Destroy.Core", scope: null, file: !48, line: 16, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !102)
|
||||
// CHECK:STDOUT: !99 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.680fc8e588bd03e0:core.Destroy.Core", scope: null, file: !48, line: 11, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !102)
|
||||
// CHECK:STDOUT: !100 = !DILocalVariable(arg: 1, scope: !99, type: !50)
|
||||
// CHECK:STDOUT: !101 = !DILocation(line: 16, column: 1, scope: !99)
|
||||
// CHECK:STDOUT: !101 = !DILocation(line: 11, column: 1, scope: !99)
|
||||
// CHECK:STDOUT: !102 = !{!100}
|
||||
// CHECK:STDOUT: !103 = distinct !DISubprogram(name: "CallLayoutC__carbon_thunk", linkageName: "_CCallLayoutC__carbon_thunk.Main", scope: null, file: !48, line: 23, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !106)
|
||||
// CHECK:STDOUT: !103 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.680fc8e588bd03e0:core.Destroy.Core", scope: null, file: !48, line: 11, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !106)
|
||||
// CHECK:STDOUT: !104 = !DILocalVariable(arg: 1, scope: !103, type: !50)
|
||||
// CHECK:STDOUT: !105 = !DILocation(line: 23, column: 1, scope: !103)
|
||||
// CHECK:STDOUT: !105 = !DILocation(line: 11, column: 1, scope: !103)
|
||||
// CHECK:STDOUT: !106 = !{!104}
|
||||
// CHECK:STDOUT: !107 = !{!"p1 _ZTSN6Carbon7LayoutAE", !2, i64 0}
|
||||
// CHECK:STDOUT: !108 = !{!107, !107, i64 0}
|
||||
// CHECK:STDOUT: !109 = !{!"p1 _ZTSN6Carbon7LayoutBE", !2, i64 0}
|
||||
// CHECK:STDOUT: !110 = !{!109, !109, i64 0}
|
||||
// CHECK:STDOUT: !111 = !{!"p1 _ZTSN6Carbon7LayoutCE", !2, i64 0}
|
||||
// CHECK:STDOUT: !112 = !{!111, !111, i64 0}
|
||||
// CHECK:STDOUT: !107 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.98b9397038fd95a2:core.Destroy.Core", scope: null, file: !48, line: 11, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !110)
|
||||
// CHECK:STDOUT: !108 = !DILocalVariable(arg: 1, scope: !107, type: !50)
|
||||
// CHECK:STDOUT: !109 = !DILocation(line: 11, column: 1, scope: !107)
|
||||
// CHECK:STDOUT: !110 = !{!108}
|
||||
// CHECK:STDOUT: !111 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.98b9397038fd95a2:core.Destroy.Core", scope: null, file: !48, line: 11, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !114)
|
||||
// CHECK:STDOUT: !112 = !DILocalVariable(arg: 1, scope: !111, type: !50)
|
||||
// CHECK:STDOUT: !113 = !DILocation(line: 11, column: 1, scope: !111)
|
||||
// CHECK:STDOUT: !114 = !{!112}
|
||||
// CHECK:STDOUT: !115 = distinct !DISubprogram(name: "CallLayoutB__carbon_thunk", linkageName: "_CCallLayoutB__carbon_thunk.Main", scope: null, file: !48, line: 22, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !118)
|
||||
// CHECK:STDOUT: !116 = !DILocalVariable(arg: 1, scope: !115, type: !50)
|
||||
// CHECK:STDOUT: !117 = !DILocation(line: 22, column: 1, scope: !115)
|
||||
// CHECK:STDOUT: !118 = !{!116}
|
||||
// CHECK:STDOUT: !119 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.LayoutC.Main", scope: null, file: !48, line: 16, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !122)
|
||||
// CHECK:STDOUT: !120 = !DILocalVariable(arg: 1, scope: !119, type: !50)
|
||||
// CHECK:STDOUT: !121 = !DILocation(line: 16, column: 1, scope: !119)
|
||||
// CHECK:STDOUT: !122 = !{!120}
|
||||
// CHECK:STDOUT: !123 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.d1ce4198d9e72e02:core.Destroy.Core", scope: null, file: !48, line: 16, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !126)
|
||||
// CHECK:STDOUT: !124 = !DILocalVariable(arg: 1, scope: !123, type: !50)
|
||||
// CHECK:STDOUT: !125 = !DILocation(line: 16, column: 1, scope: !123)
|
||||
// CHECK:STDOUT: !126 = !{!124}
|
||||
// CHECK:STDOUT: !127 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.d1ce4198d9e72e02:core.Destroy.Core", scope: null, file: !48, line: 16, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !130)
|
||||
// CHECK:STDOUT: !128 = !DILocalVariable(arg: 1, scope: !127, type: !50)
|
||||
// CHECK:STDOUT: !129 = !DILocation(line: 16, column: 1, scope: !127)
|
||||
// CHECK:STDOUT: !130 = !{!128}
|
||||
// CHECK:STDOUT: !131 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.bb6bd82e06513595:core.Destroy.Core", scope: null, file: !48, line: 16, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !134)
|
||||
// CHECK:STDOUT: !132 = !DILocalVariable(arg: 1, scope: !131, type: !50)
|
||||
// CHECK:STDOUT: !133 = !DILocation(line: 16, column: 1, scope: !131)
|
||||
// CHECK:STDOUT: !134 = !{!132}
|
||||
// CHECK:STDOUT: !135 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.bb6bd82e06513595:core.Destroy.Core", scope: null, file: !48, line: 16, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !138)
|
||||
// CHECK:STDOUT: !136 = !DILocalVariable(arg: 1, scope: !135, type: !50)
|
||||
// CHECK:STDOUT: !137 = !DILocation(line: 16, column: 1, scope: !135)
|
||||
// CHECK:STDOUT: !138 = !{!136}
|
||||
// CHECK:STDOUT: !139 = distinct !DISubprogram(name: "CallLayoutC__carbon_thunk", linkageName: "_CCallLayoutC__carbon_thunk.Main", scope: null, file: !48, line: 23, type: !52, spFlags: DISPFlagDefinition, unit: !49, retainedNodes: !142)
|
||||
// CHECK:STDOUT: !140 = !DILocalVariable(arg: 1, scope: !139, type: !50)
|
||||
// CHECK:STDOUT: !141 = !DILocation(line: 23, column: 1, scope: !139)
|
||||
// CHECK:STDOUT: !142 = !{!140}
|
||||
// CHECK:STDOUT: !143 = !{!"p1 _ZTSN6Carbon7LayoutAE", !2, i64 0}
|
||||
// CHECK:STDOUT: !144 = !{!143, !143, i64 0}
|
||||
// CHECK:STDOUT: !145 = !{!"p1 _ZTSN6Carbon7LayoutBE", !2, i64 0}
|
||||
// CHECK:STDOUT: !146 = !{!145, !145, i64 0}
|
||||
// CHECK:STDOUT: !147 = !{!"p1 _ZTSN6Carbon7LayoutCE", !2, i64 0}
|
||||
// CHECK:STDOUT: !148 = !{!147, !147, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'field.carbon'
|
||||
@@ -477,41 +574,68 @@ fn G() {
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.FieldC.Main"(ptr %self) #1 !dbg !115 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.FieldC.Main"(ptr %self) #1 !dbg !151 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.718874c3c75b803e:core.Destroy.Core"(ptr %self), !dbg !117
|
||||
// CHECK:STDOUT: ret void, !dbg !117
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.718874c3c75b803e:core.Destroy.Core"(ptr %self), !dbg !153
|
||||
// CHECK:STDOUT: ret void, !dbg !153
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.f58524831c37807e:core.Destroy.Core"(ptr %self) #2 !dbg !119 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.6dae29ece9a708c4:core.Destroy.Core"(ptr %self) #2 !dbg !155 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !121
|
||||
// CHECK:STDOUT: ret void, !dbg !157
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.b4c762864cd9a02b:core.Destroy.Core"(ptr %self) #2 !dbg !123 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core"(ptr %self) #2 !dbg !159 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !125
|
||||
// CHECK:STDOUT: ret void, !dbg !161
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.718874c3c75b803e:core.Destroy.Core"(ptr %self) #2 !dbg !127 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.f58524831c37807e:core.Destroy.Core"(ptr %self) #2 !dbg !163 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !129
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core"(ptr %self), !dbg !165
|
||||
// CHECK:STDOUT: ret void, !dbg !165
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CG.Main() #2 !dbg !131 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.b4c762864cd9a02b:core.Destroy.Core"(ptr %self) #2 !dbg !167 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %c.var = alloca { i32, i32 }, align 4, !dbg !132
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %c.var), !dbg !132
|
||||
// CHECK:STDOUT: %.loc19_34.3.a = getelementptr inbounds nuw { i32, i32 }, ptr %c.var, i32 0, i32 0, !dbg !133
|
||||
// CHECK:STDOUT: %.loc19_34.6.b = getelementptr inbounds nuw { i32, i32 }, ptr %c.var, i32 0, i32 1, !dbg !133
|
||||
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 4 %c.var, ptr align 4 @FieldC.val.loc19_3, i64 8, i1 false), !dbg !132
|
||||
// CHECK:STDOUT: call void @_Z1FRN6Carbon6FieldCE(ptr %c.var), !dbg !137
|
||||
// CHECK:STDOUT: call void @"_COp.718874c3c75b803e:core.Destroy.Core"(ptr %c.var), !dbg !132
|
||||
// CHECK:STDOUT: ret void, !dbg !138
|
||||
// CHECK:STDOUT: ret void, !dbg !169
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.b4c762864cd9a02b:core.Destroy.Core"(ptr %self) #2 !dbg !171 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.b4c762864cd9a02b:core.Destroy.Core"(ptr %self), !dbg !173
|
||||
// CHECK:STDOUT: ret void, !dbg !173
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.718874c3c75b803e:core.Destroy.Core"(ptr %self) #2 !dbg !175 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !177
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.718874c3c75b803e:core.Destroy.Core"(ptr %self) #2 !dbg !179 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.718874c3c75b803e:core.Destroy.Core"(ptr %self), !dbg !181
|
||||
// CHECK:STDOUT: ret void, !dbg !181
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CG.Main() #2 !dbg !183 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %c.var = alloca { i32, i32 }, align 4, !dbg !184
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %c.var), !dbg !184
|
||||
// CHECK:STDOUT: %.loc19_34.3.a = getelementptr inbounds nuw { i32, i32 }, ptr %c.var, i32 0, i32 0, !dbg !185
|
||||
// CHECK:STDOUT: %.loc19_34.6.b = getelementptr inbounds nuw { i32, i32 }, ptr %c.var, i32 0, i32 1, !dbg !185
|
||||
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 4 %c.var, ptr align 4 @FieldC.val.loc19_3, i64 8, i1 false), !dbg !184
|
||||
// CHECK:STDOUT: call void @_Z1FRN6Carbon6FieldCE(ptr %c.var), !dbg !189
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.718874c3c75b803e:core.Destroy.Core"(ptr %c.var), !dbg !184
|
||||
// CHECK:STDOUT: ret void, !dbg !190
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
@@ -525,7 +649,7 @@ fn G() {
|
||||
// CHECK:STDOUT: attributes #2 = { nounwind }
|
||||
// CHECK:STDOUT: attributes #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!114}
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!150}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!43, !44, !45, !19, !20}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!47}
|
||||
// CHECK:STDOUT:
|
||||
@@ -555,27 +679,43 @@ fn G() {
|
||||
// CHECK:STDOUT: !52 = !DISubroutineType(types: !51)
|
||||
// CHECK:STDOUT: !53 = !{null, !37}
|
||||
// CHECK:STDOUT: !54 = !DISubroutineType(types: !53)
|
||||
// CHECK:STDOUT: !113 = !DIFile(filename: "field.carbon", directory: "")
|
||||
// CHECK:STDOUT: !114 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !113, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !115 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.FieldC.Main", scope: null, file: !113, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !114, retainedNodes: !118)
|
||||
// CHECK:STDOUT: !116 = !DILocalVariable(arg: 1, scope: !115, type: !50)
|
||||
// CHECK:STDOUT: !117 = !DILocation(line: 6, column: 1, scope: !115)
|
||||
// CHECK:STDOUT: !118 = !{!116}
|
||||
// CHECK:STDOUT: !119 = distinct !DISubprogram(name: "Op", linkageName: "_COp.f58524831c37807e:core.Destroy.Core", scope: null, file: !113, line: 6, type: !54, spFlags: DISPFlagDefinition, unit: !114, retainedNodes: !122)
|
||||
// CHECK:STDOUT: !120 = !DILocalVariable(arg: 1, scope: !119, type: !37)
|
||||
// CHECK:STDOUT: !121 = !DILocation(line: 6, column: 1, scope: !119)
|
||||
// CHECK:STDOUT: !122 = !{!120}
|
||||
// CHECK:STDOUT: !123 = distinct !DISubprogram(name: "Op", linkageName: "_COp.b4c762864cd9a02b:core.Destroy.Core", scope: null, file: !113, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !114, retainedNodes: !126)
|
||||
// CHECK:STDOUT: !124 = !DILocalVariable(arg: 1, scope: !123, type: !50)
|
||||
// CHECK:STDOUT: !125 = !DILocation(line: 6, column: 1, scope: !123)
|
||||
// CHECK:STDOUT: !126 = !{!124}
|
||||
// CHECK:STDOUT: !127 = distinct !DISubprogram(name: "Op", linkageName: "_COp.718874c3c75b803e:core.Destroy.Core", scope: null, file: !113, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !114, retainedNodes: !130)
|
||||
// CHECK:STDOUT: !128 = !DILocalVariable(arg: 1, scope: !127, type: !50)
|
||||
// CHECK:STDOUT: !129 = !DILocation(line: 6, column: 1, scope: !127)
|
||||
// CHECK:STDOUT: !130 = !{!128}
|
||||
// CHECK:STDOUT: !131 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main", scope: null, file: !113, line: 18, type: !39, spFlags: DISPFlagDefinition, unit: !114)
|
||||
// CHECK:STDOUT: !132 = !DILocation(line: 19, column: 3, scope: !131)
|
||||
// CHECK:STDOUT: !133 = !DILocation(line: 19, column: 19, scope: !131)
|
||||
// CHECK:STDOUT: !137 = !DILocation(line: 20, column: 3, scope: !131)
|
||||
// CHECK:STDOUT: !138 = !DILocation(line: 18, column: 1, scope: !131)
|
||||
// CHECK:STDOUT: !149 = !DIFile(filename: "field.carbon", directory: "")
|
||||
// CHECK:STDOUT: !150 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !149, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !151 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.FieldC.Main", scope: null, file: !149, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !150, retainedNodes: !154)
|
||||
// CHECK:STDOUT: !152 = !DILocalVariable(arg: 1, scope: !151, type: !50)
|
||||
// CHECK:STDOUT: !153 = !DILocation(line: 6, column: 1, scope: !151)
|
||||
// CHECK:STDOUT: !154 = !{!152}
|
||||
// CHECK:STDOUT: !155 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.6dae29ece9a708c4:core.Destroy.Core", scope: null, file: !149, line: 6, type: !54, spFlags: DISPFlagDefinition, unit: !150, retainedNodes: !158)
|
||||
// CHECK:STDOUT: !156 = !DILocalVariable(arg: 1, scope: !155, type: !37)
|
||||
// CHECK:STDOUT: !157 = !DILocation(line: 6, column: 1, scope: !155)
|
||||
// CHECK:STDOUT: !158 = !{!156}
|
||||
// CHECK:STDOUT: !159 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core", scope: null, file: !149, line: 6, type: !54, spFlags: DISPFlagDefinition, unit: !150, retainedNodes: !162)
|
||||
// CHECK:STDOUT: !160 = !DILocalVariable(arg: 1, scope: !159, type: !37)
|
||||
// CHECK:STDOUT: !161 = !DILocation(line: 6, column: 1, scope: !159)
|
||||
// CHECK:STDOUT: !162 = !{!160}
|
||||
// CHECK:STDOUT: !163 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.f58524831c37807e:core.Destroy.Core", scope: null, file: !149, line: 6, type: !54, spFlags: DISPFlagDefinition, unit: !150, retainedNodes: !166)
|
||||
// CHECK:STDOUT: !164 = !DILocalVariable(arg: 1, scope: !163, type: !37)
|
||||
// CHECK:STDOUT: !165 = !DILocation(line: 6, column: 1, scope: !163)
|
||||
// CHECK:STDOUT: !166 = !{!164}
|
||||
// CHECK:STDOUT: !167 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.b4c762864cd9a02b:core.Destroy.Core", scope: null, file: !149, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !150, retainedNodes: !170)
|
||||
// CHECK:STDOUT: !168 = !DILocalVariable(arg: 1, scope: !167, type: !50)
|
||||
// CHECK:STDOUT: !169 = !DILocation(line: 6, column: 1, scope: !167)
|
||||
// CHECK:STDOUT: !170 = !{!168}
|
||||
// CHECK:STDOUT: !171 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.b4c762864cd9a02b:core.Destroy.Core", scope: null, file: !149, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !150, retainedNodes: !174)
|
||||
// CHECK:STDOUT: !172 = !DILocalVariable(arg: 1, scope: !171, type: !50)
|
||||
// CHECK:STDOUT: !173 = !DILocation(line: 6, column: 1, scope: !171)
|
||||
// CHECK:STDOUT: !174 = !{!172}
|
||||
// CHECK:STDOUT: !175 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.718874c3c75b803e:core.Destroy.Core", scope: null, file: !149, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !150, retainedNodes: !178)
|
||||
// CHECK:STDOUT: !176 = !DILocalVariable(arg: 1, scope: !175, type: !50)
|
||||
// CHECK:STDOUT: !177 = !DILocation(line: 6, column: 1, scope: !175)
|
||||
// CHECK:STDOUT: !178 = !{!176}
|
||||
// CHECK:STDOUT: !179 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.718874c3c75b803e:core.Destroy.Core", scope: null, file: !149, line: 6, type: !52, spFlags: DISPFlagDefinition, unit: !150, retainedNodes: !182)
|
||||
// CHECK:STDOUT: !180 = !DILocalVariable(arg: 1, scope: !179, type: !50)
|
||||
// CHECK:STDOUT: !181 = !DILocation(line: 6, column: 1, scope: !179)
|
||||
// CHECK:STDOUT: !182 = !{!180}
|
||||
// CHECK:STDOUT: !183 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main", scope: null, file: !149, line: 18, type: !39, spFlags: DISPFlagDefinition, unit: !150)
|
||||
// CHECK:STDOUT: !184 = !DILocation(line: 19, column: 3, scope: !183)
|
||||
// CHECK:STDOUT: !185 = !DILocation(line: 19, column: 19, scope: !183)
|
||||
// CHECK:STDOUT: !189 = !DILocation(line: 20, column: 3, scope: !183)
|
||||
// CHECK:STDOUT: !190 = !DILocation(line: 18, column: 1, scope: !183)
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -0,0 +1,142 @@
|
||||
// Part of the Carbon Language project, under the Apache License v2.0 with LLVM
|
||||
// Exceptions. See /LICENSE for license information.
|
||||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
||||
//
|
||||
// INCLUDE-FILE: toolchain/testing/testdata/min_prelude/full.carbon
|
||||
//
|
||||
// AUTOUPDATE
|
||||
// TIP: To test this file alone, run:
|
||||
// TIP: bazel test //toolchain/testing:file_test --test_arg=--file_tests=toolchain/lower/testdata/interop/cpp/class/export/destroy_from_thunk.carbon
|
||||
// TIP: To dump output, run:
|
||||
// TIP: bazel run //toolchain/testing:file_test -- --dump_output --file_tests=toolchain/lower/testdata/interop/cpp/class/export/destroy_from_thunk.carbon
|
||||
|
||||
// --- memory.h
|
||||
|
||||
template<class T>
|
||||
auto make_unique() -> void {
|
||||
T();
|
||||
}
|
||||
|
||||
// --- a.carbon
|
||||
|
||||
import Cpp library "memory.h";
|
||||
|
||||
class C {}
|
||||
|
||||
fn Run() {
|
||||
Cpp.make_unique(C);
|
||||
}
|
||||
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'a.carbon'
|
||||
// CHECK:STDOUT: source_filename = "a.carbon"
|
||||
// CHECK:STDOUT: target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
|
||||
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: %"class.Carbon::C" = type {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: $_Z11make_uniqueIN6Carbon1CEEvv = comdat any
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: $_ZN6Carbon1CD2Ev = comdat any
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i32 @main() #0 !dbg !14 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z11make_uniqueIN6Carbon1CEEvv(), !dbg !15
|
||||
// CHECK:STDOUT: ret i32 0, !dbg !16
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: mustprogress nounwind uwtable
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_Z11make_uniqueIN6Carbon1CEEvv() #1 comdat {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %agg.tmp.ensured = alloca %"class.Carbon::C", align 1
|
||||
// CHECK:STDOUT: call void @_ZN6Carbon1CD2Ev(ptr noundef nonnull align 1 %agg.tmp.ensured) #0
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.C.Main"(ptr %self) #2 !dbg !17 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.08d9e38b928ba575:core.Destroy.Core"(ptr %self), !dbg !19
|
||||
// CHECK:STDOUT: ret void, !dbg !19
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.cb8adced19392b99:core.Destroy.Core"(ptr %self) #0 !dbg !21 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !23
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.08d9e38b928ba575:core.Destroy.Core"(ptr %self) #0 !dbg !25 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !27
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.08d9e38b928ba575:core.Destroy.Core"(ptr %self) #0 !dbg !29 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.08d9e38b928ba575:core.Destroy.Core"(ptr %self), !dbg !31
|
||||
// CHECK:STDOUT: ret void, !dbg !31
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: inlinehint mustprogress nounwind uwtable
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN6Carbon1CD2Ev(ptr noundef nonnull align 1 %this) unnamed_addr #3 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !37
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @"_C__destroy_thunk:thunk.C.Main"(ptr noundef nonnull align 1 %this1)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: attributes #0 = { nounwind }
|
||||
// CHECK:STDOUT: attributes #1 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT: attributes #2 = { alwaysinline nounwind }
|
||||
// CHECK:STDOUT: attributes #3 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!5}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!39, !40, !41, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!44}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
// CHECK:STDOUT: !4 = !DIFile(filename: "a.carbon", directory: "")
|
||||
// CHECK:STDOUT: !5 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !4, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !6 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
|
||||
// CHECK:STDOUT: !7 = !{!6}
|
||||
// CHECK:STDOUT: !8 = !DISubroutineType(types: !7)
|
||||
// CHECK:STDOUT: !11 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
|
||||
// CHECK:STDOUT: !12 = !{null, !11}
|
||||
// CHECK:STDOUT: !13 = !DISubroutineType(types: !12)
|
||||
// CHECK:STDOUT: !14 = distinct !DISubprogram(name: "Run", linkageName: "main", scope: null, file: !4, line: 6, type: !8, spFlags: DISPFlagDefinition, unit: !5)
|
||||
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 3, scope: !14)
|
||||
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 1, scope: !14)
|
||||
// CHECK:STDOUT: !17 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.C.Main", scope: null, file: !4, line: 4, type: !13, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !20)
|
||||
// CHECK:STDOUT: !18 = !DILocalVariable(arg: 1, scope: !17, type: !11)
|
||||
// CHECK:STDOUT: !19 = !DILocation(line: 4, column: 1, scope: !17)
|
||||
// CHECK:STDOUT: !20 = !{!18}
|
||||
// CHECK:STDOUT: !21 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.cb8adced19392b99:core.Destroy.Core", scope: null, file: !4, line: 4, type: !13, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !24)
|
||||
// CHECK:STDOUT: !22 = !DILocalVariable(arg: 1, scope: !21, type: !11)
|
||||
// CHECK:STDOUT: !23 = !DILocation(line: 4, column: 1, scope: !21)
|
||||
// CHECK:STDOUT: !24 = !{!22}
|
||||
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.08d9e38b928ba575:core.Destroy.Core", scope: null, file: !4, line: 4, type: !13, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !28)
|
||||
// CHECK:STDOUT: !26 = !DILocalVariable(arg: 1, scope: !25, type: !11)
|
||||
// CHECK:STDOUT: !27 = !DILocation(line: 4, column: 1, scope: !25)
|
||||
// CHECK:STDOUT: !28 = !{!26}
|
||||
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.08d9e38b928ba575:core.Destroy.Core", scope: null, file: !4, line: 4, type: !13, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !32)
|
||||
// CHECK:STDOUT: !30 = !DILocalVariable(arg: 1, scope: !29, type: !11)
|
||||
// CHECK:STDOUT: !31 = !DILocation(line: 4, column: 1, scope: !29)
|
||||
// CHECK:STDOUT: !32 = !{!30}
|
||||
// CHECK:STDOUT: !33 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !34 = !{!"omnipotent char", !33, i64 0}
|
||||
// CHECK:STDOUT: !35 = !{!"any pointer", !34, i64 0}
|
||||
// CHECK:STDOUT: !36 = !{!"p1 _ZTSN6Carbon1CE", !35, i64 0}
|
||||
// CHECK:STDOUT: !37 = !{!36, !36, i64 0}
|
||||
// CHECK:STDOUT: !39 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !40 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !41 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !42 = !{!"int", !34, i64 0}
|
||||
// CHECK:STDOUT: !43 = !{!"__libc_errno", !42, i64 0}
|
||||
// CHECK:STDOUT: !44 = !{!43, !42, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
+191
-128
@@ -91,7 +91,7 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: define internal void @_ZNK6Carbon1A1FEv(ptr noundef nonnull align 1 %this) #2 align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !47
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !55
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @_CF__carbon_thunk.A.Main(ptr noundef nonnull align 1 %this1)
|
||||
// CHECK:STDOUT: ret void
|
||||
@@ -101,7 +101,7 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN6Carbon1AD2Ev(ptr noundef nonnull align 1 %this) unnamed_addr #3 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !47
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !55
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @"_C__destroy_thunk:thunk.A.Main"(ptr noundef nonnull align 1 %this1)
|
||||
// CHECK:STDOUT: ret void
|
||||
@@ -119,23 +119,36 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.A.Main"(ptr %self) #5 !dbg !31 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.5a23cc09585c55d2:core.Destroy.Core"(ptr %self), !dbg !33
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.5a23cc09585c55d2:core.Destroy.Core"(ptr %self), !dbg !33
|
||||
// CHECK:STDOUT: ret void, !dbg !33
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.5a23cc09585c55d2:core.Destroy.Core"(ptr %self) #4 !dbg !35 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.cb8adced19392b99:core.Destroy.Core"(ptr %self) #4 !dbg !35 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !37
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.A.Main(ptr %self) #4 !dbg !39 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.5a23cc09585c55d2:core.Destroy.Core"(ptr %self) #4 !dbg !39 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.A.Main(ptr %self), !dbg !41
|
||||
// CHECK:STDOUT: ret void, !dbg !41
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.5a23cc09585c55d2:core.Destroy.Core"(ptr %self) #4 !dbg !43 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.5a23cc09585c55d2:core.Destroy.Core"(ptr %self), !dbg !45
|
||||
// CHECK:STDOUT: ret void, !dbg !45
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.A.Main(ptr %self) #4 !dbg !47 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.A.Main(ptr %self), !dbg !49
|
||||
// CHECK:STDOUT: ret void, !dbg !49
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT: attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
|
||||
// CHECK:STDOUT: attributes #2 = { alwaysinline mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
@@ -144,8 +157,8 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: attributes #5 = { alwaysinline nounwind }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!21}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!48, !49, !50, !4, !5}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!53}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!56, !57, !58, !4, !5}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!61}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !4 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !5 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -162,25 +175,33 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: !32 = !DILocalVariable(arg: 1, scope: !31, type: !22)
|
||||
// CHECK:STDOUT: !33 = !DILocation(line: 5, column: 1, scope: !31)
|
||||
// CHECK:STDOUT: !34 = !{!32}
|
||||
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5a23cc09585c55d2:core.Destroy.Core", scope: null, file: !20, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !21, retainedNodes: !38)
|
||||
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.cb8adced19392b99:core.Destroy.Core", scope: null, file: !20, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !21, retainedNodes: !38)
|
||||
// CHECK:STDOUT: !36 = !DILocalVariable(arg: 1, scope: !35, type: !22)
|
||||
// CHECK:STDOUT: !37 = !DILocation(line: 5, column: 1, scope: !35)
|
||||
// CHECK:STDOUT: !38 = !{!36}
|
||||
// CHECK:STDOUT: !39 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.A.Main", scope: null, file: !20, line: 6, type: !24, spFlags: DISPFlagDefinition, unit: !21, retainedNodes: !42)
|
||||
// CHECK:STDOUT: !39 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.5a23cc09585c55d2:core.Destroy.Core", scope: null, file: !20, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !21, retainedNodes: !42)
|
||||
// CHECK:STDOUT: !40 = !DILocalVariable(arg: 1, scope: !39, type: !22)
|
||||
// CHECK:STDOUT: !41 = !DILocation(line: 6, column: 3, scope: !39)
|
||||
// CHECK:STDOUT: !41 = !DILocation(line: 5, column: 1, scope: !39)
|
||||
// CHECK:STDOUT: !42 = !{!40}
|
||||
// CHECK:STDOUT: !43 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !44 = !{!"omnipotent char", !43, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{!"any pointer", !44, i64 0}
|
||||
// CHECK:STDOUT: !46 = !{!"p1 _ZTSN6Carbon1AE", !45, i64 0}
|
||||
// CHECK:STDOUT: !47 = !{!46, !46, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !49 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !50 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !51 = !{!"int", !44, i64 0}
|
||||
// CHECK:STDOUT: !52 = !{!"__libc_errno", !51, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!52, !51, i64 0}
|
||||
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.5a23cc09585c55d2:core.Destroy.Core", scope: null, file: !20, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !21, retainedNodes: !46)
|
||||
// CHECK:STDOUT: !44 = !DILocalVariable(arg: 1, scope: !43, type: !22)
|
||||
// CHECK:STDOUT: !45 = !DILocation(line: 5, column: 1, scope: !43)
|
||||
// CHECK:STDOUT: !46 = !{!44}
|
||||
// CHECK:STDOUT: !47 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.A.Main", scope: null, file: !20, line: 6, type: !24, spFlags: DISPFlagDefinition, unit: !21, retainedNodes: !50)
|
||||
// CHECK:STDOUT: !48 = !DILocalVariable(arg: 1, scope: !47, type: !22)
|
||||
// CHECK:STDOUT: !49 = !DILocation(line: 6, column: 3, scope: !47)
|
||||
// CHECK:STDOUT: !50 = !{!48}
|
||||
// CHECK:STDOUT: !51 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !52 = !{!"omnipotent char", !51, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!"any pointer", !52, i64 0}
|
||||
// CHECK:STDOUT: !54 = !{!"p1 _ZTSN6Carbon1AE", !53, i64 0}
|
||||
// CHECK:STDOUT: !55 = !{!54, !54, i64 0}
|
||||
// CHECK:STDOUT: !56 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !57 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !58 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !59 = !{!"int", !52, i64 0}
|
||||
// CHECK:STDOUT: !60 = !{!"__libc_errno", !59, i64 0}
|
||||
// CHECK:STDOUT: !61 = !{!60, !59, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'method_with_args_and_return.carbon'
|
||||
@@ -212,8 +233,8 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: %retval = alloca i32, align 4
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %.addr = alloca i32, align 4
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !94
|
||||
// CHECK:STDOUT: store i32 %0, ptr %.addr, align 4, !tbaa !95
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: store i32 %0, ptr %.addr, align 4, !tbaa !111
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @_CF__carbon_thunk.ArgsA.Main(ptr noundef nonnull align 1 %this1, ptr noundef nonnull align 4 dereferenceable(4) %.addr, ptr noundef nonnull align 4 dereferenceable(4) %retval)
|
||||
// CHECK:STDOUT: %1 = load i32, ptr %retval, align 4
|
||||
@@ -224,7 +245,7 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN6Carbon5ArgsAD2Ev(ptr noundef nonnull align 1 %this) unnamed_addr #3 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !94
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @"_C__destroy_thunk:thunk.ArgsA.Main"(ptr noundef nonnull align 1 %this1)
|
||||
// CHECK:STDOUT: ret void
|
||||
@@ -234,38 +255,51 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: declare void @llvm.lifetime.end.p0(ptr captures(none)) #1
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i32 @_CF.ArgsA.Main(ptr %self, i32 %a) #4 !dbg !63 {
|
||||
// CHECK:STDOUT: define i32 @_CF.ArgsA.Main(ptr %self, i32 %a) #4 !dbg !71 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret i32 %a, !dbg !72
|
||||
// CHECK:STDOUT: ret i32 %a, !dbg !80
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.ArgsA.Main"(ptr %self) #5 !dbg !74 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.ArgsA.Main"(ptr %self) #5 !dbg !82 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.eefdfd667b52bf5b:core.Destroy.Core"(ptr %self), !dbg !76
|
||||
// CHECK:STDOUT: ret void, !dbg !76
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.eefdfd667b52bf5b:core.Destroy.Core"(ptr %self), !dbg !84
|
||||
// CHECK:STDOUT: ret void, !dbg !84
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.eefdfd667b52bf5b:core.Destroy.Core"(ptr %self) #4 !dbg !78 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.cb8adced19392b99:core.Destroy.Core"(ptr %self) #4 !dbg !86 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !80
|
||||
// CHECK:STDOUT: ret void, !dbg !88
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.ArgsA.Main(ptr %self, ptr %_, ptr %_1) #4 !dbg !82 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.eefdfd667b52bf5b:core.Destroy.Core"(ptr %self) #4 !dbg !90 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc6_29.2 = load i32, ptr %_, align 4, !dbg !86
|
||||
// CHECK:STDOUT: %ArgsA.F.call = call i32 @_CF.ArgsA.Main(ptr %self, i32 %.loc6_29.2), !dbg !86
|
||||
// CHECK:STDOUT: store i32 %ArgsA.F.call, ptr %_1, align 4, !dbg !86
|
||||
// CHECK:STDOUT: ret void, !dbg !86
|
||||
// CHECK:STDOUT: ret void, !dbg !92
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i32 @_CCallCallF.Main() #4 !dbg !88 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.eefdfd667b52bf5b:core.Destroy.Core"(ptr %self) #4 !dbg !94 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %CallArgsF.call = call i32 @_Z9CallArgsFv(), !dbg !91
|
||||
// CHECK:STDOUT: ret i32 %CallArgsF.call, !dbg !92
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.eefdfd667b52bf5b:core.Destroy.Core"(ptr %self), !dbg !96
|
||||
// CHECK:STDOUT: ret void, !dbg !96
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.ArgsA.Main(ptr %self, ptr %_, ptr %_1) #4 !dbg !98 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc6_29.2 = load i32, ptr %_, align 4, !dbg !102
|
||||
// CHECK:STDOUT: %ArgsA.F.call = call i32 @_CF.ArgsA.Main(ptr %self, i32 %.loc6_29.2), !dbg !102
|
||||
// CHECK:STDOUT: store i32 %ArgsA.F.call, ptr %_1, align 4, !dbg !102
|
||||
// CHECK:STDOUT: ret void, !dbg !102
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i32 @_CCallCallF.Main() #4 !dbg !104 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %CallArgsF.call = call i32 @_Z9CallArgsFv(), !dbg !107
|
||||
// CHECK:STDOUT: ret i32 %CallArgsF.call, !dbg !108
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
@@ -275,58 +309,66 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: attributes #4 = { nounwind }
|
||||
// CHECK:STDOUT: attributes #5 = { alwaysinline nounwind }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!55}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!48, !49, !50, !4, !5}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!53}
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!63}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!56, !57, !58, !4, !5}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!61}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !4 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !5 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
// CHECK:STDOUT: !22 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
|
||||
// CHECK:STDOUT: !23 = !{null, !22}
|
||||
// CHECK:STDOUT: !24 = !DISubroutineType(types: !23)
|
||||
// CHECK:STDOUT: !43 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !44 = !{!"omnipotent char", !43, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{!"any pointer", !44, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !49 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !50 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !51 = !{!"int", !44, i64 0}
|
||||
// CHECK:STDOUT: !52 = !{!"__libc_errno", !51, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!52, !51, i64 0}
|
||||
// CHECK:STDOUT: !54 = !DIFile(filename: "method_with_args_and_return.carbon", directory: "")
|
||||
// CHECK:STDOUT: !55 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !54, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !56 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
|
||||
// CHECK:STDOUT: !57 = !{!56, !22, !56}
|
||||
// CHECK:STDOUT: !58 = !DISubroutineType(types: !57)
|
||||
// CHECK:STDOUT: !59 = !{null, !22, !56, !56}
|
||||
// CHECK:STDOUT: !60 = !DISubroutineType(types: !59)
|
||||
// CHECK:STDOUT: !61 = !{!56}
|
||||
// CHECK:STDOUT: !62 = !DISubroutineType(types: !61)
|
||||
// CHECK:STDOUT: !63 = distinct !DISubprogram(name: "F", linkageName: "_CF.ArgsA.Main", scope: null, file: !54, line: 6, type: !58, spFlags: DISPFlagDefinition, unit: !55, retainedNodes: !73)
|
||||
// CHECK:STDOUT: !64 = !DILocalVariable(arg: 1, scope: !63, type: !22)
|
||||
// CHECK:STDOUT: !65 = !DILocalVariable(arg: 2, scope: !63, type: !56)
|
||||
// CHECK:STDOUT: !72 = !DILocation(line: 8, column: 5, scope: !63)
|
||||
// CHECK:STDOUT: !73 = !{!64, !65}
|
||||
// CHECK:STDOUT: !74 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.ArgsA.Main", scope: null, file: !54, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !55, retainedNodes: !77)
|
||||
// CHECK:STDOUT: !75 = !DILocalVariable(arg: 1, scope: !74, type: !22)
|
||||
// CHECK:STDOUT: !76 = !DILocation(line: 5, column: 1, scope: !74)
|
||||
// CHECK:STDOUT: !77 = !{!75}
|
||||
// CHECK:STDOUT: !78 = distinct !DISubprogram(name: "Op", linkageName: "_COp.eefdfd667b52bf5b:core.Destroy.Core", scope: null, file: !54, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !55, retainedNodes: !81)
|
||||
// CHECK:STDOUT: !79 = !DILocalVariable(arg: 1, scope: !78, type: !22)
|
||||
// CHECK:STDOUT: !80 = !DILocation(line: 5, column: 1, scope: !78)
|
||||
// CHECK:STDOUT: !81 = !{!79}
|
||||
// CHECK:STDOUT: !82 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.ArgsA.Main", scope: null, file: !54, line: 6, type: !60, spFlags: DISPFlagDefinition, unit: !55, retainedNodes: !87)
|
||||
// CHECK:STDOUT: !51 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !52 = !{!"omnipotent char", !51, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!"any pointer", !52, i64 0}
|
||||
// CHECK:STDOUT: !56 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !57 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !58 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !59 = !{!"int", !52, i64 0}
|
||||
// CHECK:STDOUT: !60 = !{!"__libc_errno", !59, i64 0}
|
||||
// CHECK:STDOUT: !61 = !{!60, !59, i64 0}
|
||||
// CHECK:STDOUT: !62 = !DIFile(filename: "method_with_args_and_return.carbon", directory: "")
|
||||
// CHECK:STDOUT: !63 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !62, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !64 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
|
||||
// CHECK:STDOUT: !65 = !{!64, !22, !64}
|
||||
// CHECK:STDOUT: !66 = !DISubroutineType(types: !65)
|
||||
// CHECK:STDOUT: !67 = !{null, !22, !64, !64}
|
||||
// CHECK:STDOUT: !68 = !DISubroutineType(types: !67)
|
||||
// CHECK:STDOUT: !69 = !{!64}
|
||||
// CHECK:STDOUT: !70 = !DISubroutineType(types: !69)
|
||||
// CHECK:STDOUT: !71 = distinct !DISubprogram(name: "F", linkageName: "_CF.ArgsA.Main", scope: null, file: !62, line: 6, type: !66, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !81)
|
||||
// CHECK:STDOUT: !72 = !DILocalVariable(arg: 1, scope: !71, type: !22)
|
||||
// CHECK:STDOUT: !73 = !DILocalVariable(arg: 2, scope: !71, type: !64)
|
||||
// CHECK:STDOUT: !80 = !DILocation(line: 8, column: 5, scope: !71)
|
||||
// CHECK:STDOUT: !81 = !{!72, !73}
|
||||
// CHECK:STDOUT: !82 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.ArgsA.Main", scope: null, file: !62, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !85)
|
||||
// CHECK:STDOUT: !83 = !DILocalVariable(arg: 1, scope: !82, type: !22)
|
||||
// CHECK:STDOUT: !84 = !DILocalVariable(arg: 2, scope: !82, type: !56)
|
||||
// CHECK:STDOUT: !85 = !DILocalVariable(arg: 3, scope: !82, type: !56)
|
||||
// CHECK:STDOUT: !86 = !DILocation(line: 6, column: 3, scope: !82)
|
||||
// CHECK:STDOUT: !87 = !{!83, !84, !85}
|
||||
// CHECK:STDOUT: !88 = distinct !DISubprogram(name: "CallCallF", linkageName: "_CCallCallF.Main", scope: null, file: !54, line: 18, type: !62, spFlags: DISPFlagDefinition, unit: !55)
|
||||
// CHECK:STDOUT: !91 = !DILocation(line: 18, column: 32, scope: !88)
|
||||
// CHECK:STDOUT: !92 = !DILocation(line: 18, column: 25, scope: !88)
|
||||
// CHECK:STDOUT: !93 = !{!"p1 _ZTSN6Carbon5ArgsAE", !45, i64 0}
|
||||
// CHECK:STDOUT: !94 = !{!93, !93, i64 0}
|
||||
// CHECK:STDOUT: !95 = !{!51, !51, i64 0}
|
||||
// CHECK:STDOUT: !84 = !DILocation(line: 5, column: 1, scope: !82)
|
||||
// CHECK:STDOUT: !85 = !{!83}
|
||||
// CHECK:STDOUT: !86 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.cb8adced19392b99:core.Destroy.Core", scope: null, file: !62, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !89)
|
||||
// CHECK:STDOUT: !87 = !DILocalVariable(arg: 1, scope: !86, type: !22)
|
||||
// CHECK:STDOUT: !88 = !DILocation(line: 5, column: 1, scope: !86)
|
||||
// CHECK:STDOUT: !89 = !{!87}
|
||||
// CHECK:STDOUT: !90 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.eefdfd667b52bf5b:core.Destroy.Core", scope: null, file: !62, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !93)
|
||||
// CHECK:STDOUT: !91 = !DILocalVariable(arg: 1, scope: !90, type: !22)
|
||||
// CHECK:STDOUT: !92 = !DILocation(line: 5, column: 1, scope: !90)
|
||||
// CHECK:STDOUT: !93 = !{!91}
|
||||
// CHECK:STDOUT: !94 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.eefdfd667b52bf5b:core.Destroy.Core", scope: null, file: !62, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !97)
|
||||
// CHECK:STDOUT: !95 = !DILocalVariable(arg: 1, scope: !94, type: !22)
|
||||
// CHECK:STDOUT: !96 = !DILocation(line: 5, column: 1, scope: !94)
|
||||
// CHECK:STDOUT: !97 = !{!95}
|
||||
// CHECK:STDOUT: !98 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.ArgsA.Main", scope: null, file: !62, line: 6, type: !68, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !103)
|
||||
// CHECK:STDOUT: !99 = !DILocalVariable(arg: 1, scope: !98, type: !22)
|
||||
// CHECK:STDOUT: !100 = !DILocalVariable(arg: 2, scope: !98, type: !64)
|
||||
// CHECK:STDOUT: !101 = !DILocalVariable(arg: 3, scope: !98, type: !64)
|
||||
// CHECK:STDOUT: !102 = !DILocation(line: 6, column: 3, scope: !98)
|
||||
// CHECK:STDOUT: !103 = !{!99, !100, !101}
|
||||
// CHECK:STDOUT: !104 = distinct !DISubprogram(name: "CallCallF", linkageName: "_CCallCallF.Main", scope: null, file: !62, line: 18, type: !70, spFlags: DISPFlagDefinition, unit: !63)
|
||||
// CHECK:STDOUT: !107 = !DILocation(line: 18, column: 32, scope: !104)
|
||||
// CHECK:STDOUT: !108 = !DILocation(line: 18, column: 25, scope: !104)
|
||||
// CHECK:STDOUT: !109 = !{!"p1 _ZTSN6Carbon5ArgsAE", !53, i64 0}
|
||||
// CHECK:STDOUT: !110 = !{!109, !109, i64 0}
|
||||
// CHECK:STDOUT: !111 = !{!59, !59, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'static.carbon'
|
||||
@@ -349,36 +391,49 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF.StaticA.Main() #2 !dbg !100 {
|
||||
// CHECK:STDOUT: define void @_CF.StaticA.Main() #2 !dbg !116 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !101
|
||||
// CHECK:STDOUT: ret void, !dbg !117
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.StaticA.Main"(ptr %self) #3 !dbg !102 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.StaticA.Main"(ptr %self) #3 !dbg !118 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.1be3804f96ff0532:core.Destroy.Core"(ptr %self), !dbg !104
|
||||
// CHECK:STDOUT: ret void, !dbg !104
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.1be3804f96ff0532:core.Destroy.Core"(ptr %self), !dbg !120
|
||||
// CHECK:STDOUT: ret void, !dbg !120
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.1be3804f96ff0532:core.Destroy.Core"(ptr %self) #2 !dbg !106 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.cb8adced19392b99:core.Destroy.Core"(ptr %self) #2 !dbg !122 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !108
|
||||
// CHECK:STDOUT: ret void, !dbg !124
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.StaticA.Main() #2 !dbg !110 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.1be3804f96ff0532:core.Destroy.Core"(ptr %self) #2 !dbg !126 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.StaticA.Main(), !dbg !111
|
||||
// CHECK:STDOUT: ret void, !dbg !111
|
||||
// CHECK:STDOUT: ret void, !dbg !128
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CCallCallF.Main() #2 !dbg !112 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.1be3804f96ff0532:core.Destroy.Core"(ptr %self) #2 !dbg !130 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z11CallStaticFv(), !dbg !113
|
||||
// CHECK:STDOUT: ret void, !dbg !114
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.1be3804f96ff0532:core.Destroy.Core"(ptr %self), !dbg !132
|
||||
// CHECK:STDOUT: ret void, !dbg !132
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.StaticA.Main() #2 !dbg !134 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.StaticA.Main(), !dbg !135
|
||||
// CHECK:STDOUT: ret void, !dbg !135
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CCallCallF.Main() #2 !dbg !136 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z11CallStaticFv(), !dbg !137
|
||||
// CHECK:STDOUT: ret void, !dbg !138
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
@@ -386,40 +441,48 @@ fn CallCallF() { Cpp.CallStaticF(); }
|
||||
// CHECK:STDOUT: attributes #2 = { nounwind }
|
||||
// CHECK:STDOUT: attributes #3 = { alwaysinline nounwind }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!97}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!48, !49, !50, !4, !5}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!53}
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!113}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!56, !57, !58, !4, !5}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!61}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !4 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !5 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
// CHECK:STDOUT: !22 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
|
||||
// CHECK:STDOUT: !23 = !{null, !22}
|
||||
// CHECK:STDOUT: !24 = !DISubroutineType(types: !23)
|
||||
// CHECK:STDOUT: !43 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !44 = !{!"omnipotent char", !43, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !49 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !50 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !51 = !{!"int", !44, i64 0}
|
||||
// CHECK:STDOUT: !52 = !{!"__libc_errno", !51, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!52, !51, i64 0}
|
||||
// CHECK:STDOUT: !96 = !DIFile(filename: "static.carbon", directory: "")
|
||||
// CHECK:STDOUT: !97 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !96, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !98 = !{null}
|
||||
// CHECK:STDOUT: !99 = !DISubroutineType(types: !98)
|
||||
// CHECK:STDOUT: !100 = distinct !DISubprogram(name: "F", linkageName: "_CF.StaticA.Main", scope: null, file: !96, line: 6, type: !99, spFlags: DISPFlagDefinition, unit: !97)
|
||||
// CHECK:STDOUT: !101 = !DILocation(line: 6, column: 3, scope: !100)
|
||||
// CHECK:STDOUT: !102 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.StaticA.Main", scope: null, file: !96, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !97, retainedNodes: !105)
|
||||
// CHECK:STDOUT: !103 = !DILocalVariable(arg: 1, scope: !102, type: !22)
|
||||
// CHECK:STDOUT: !104 = !DILocation(line: 5, column: 1, scope: !102)
|
||||
// CHECK:STDOUT: !105 = !{!103}
|
||||
// CHECK:STDOUT: !106 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1be3804f96ff0532:core.Destroy.Core", scope: null, file: !96, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !97, retainedNodes: !109)
|
||||
// CHECK:STDOUT: !107 = !DILocalVariable(arg: 1, scope: !106, type: !22)
|
||||
// CHECK:STDOUT: !108 = !DILocation(line: 5, column: 1, scope: !106)
|
||||
// CHECK:STDOUT: !109 = !{!107}
|
||||
// CHECK:STDOUT: !110 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.StaticA.Main", scope: null, file: !96, line: 6, type: !99, spFlags: DISPFlagDefinition, unit: !97)
|
||||
// CHECK:STDOUT: !111 = !DILocation(line: 6, column: 3, scope: !110)
|
||||
// CHECK:STDOUT: !112 = distinct !DISubprogram(name: "CallCallF", linkageName: "_CCallCallF.Main", scope: null, file: !96, line: 15, type: !99, spFlags: DISPFlagDefinition, unit: !97)
|
||||
// CHECK:STDOUT: !113 = !DILocation(line: 15, column: 18, scope: !112)
|
||||
// CHECK:STDOUT: !114 = !DILocation(line: 15, column: 1, scope: !112)
|
||||
// CHECK:STDOUT: !51 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !52 = !{!"omnipotent char", !51, i64 0}
|
||||
// CHECK:STDOUT: !56 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !57 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !58 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !59 = !{!"int", !52, i64 0}
|
||||
// CHECK:STDOUT: !60 = !{!"__libc_errno", !59, i64 0}
|
||||
// CHECK:STDOUT: !61 = !{!60, !59, i64 0}
|
||||
// CHECK:STDOUT: !112 = !DIFile(filename: "static.carbon", directory: "")
|
||||
// CHECK:STDOUT: !113 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !112, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !114 = !{null}
|
||||
// CHECK:STDOUT: !115 = !DISubroutineType(types: !114)
|
||||
// CHECK:STDOUT: !116 = distinct !DISubprogram(name: "F", linkageName: "_CF.StaticA.Main", scope: null, file: !112, line: 6, type: !115, spFlags: DISPFlagDefinition, unit: !113)
|
||||
// CHECK:STDOUT: !117 = !DILocation(line: 6, column: 3, scope: !116)
|
||||
// CHECK:STDOUT: !118 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.StaticA.Main", scope: null, file: !112, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !113, retainedNodes: !121)
|
||||
// CHECK:STDOUT: !119 = !DILocalVariable(arg: 1, scope: !118, type: !22)
|
||||
// CHECK:STDOUT: !120 = !DILocation(line: 5, column: 1, scope: !118)
|
||||
// CHECK:STDOUT: !121 = !{!119}
|
||||
// CHECK:STDOUT: !122 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.cb8adced19392b99:core.Destroy.Core", scope: null, file: !112, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !113, retainedNodes: !125)
|
||||
// CHECK:STDOUT: !123 = !DILocalVariable(arg: 1, scope: !122, type: !22)
|
||||
// CHECK:STDOUT: !124 = !DILocation(line: 5, column: 1, scope: !122)
|
||||
// CHECK:STDOUT: !125 = !{!123}
|
||||
// CHECK:STDOUT: !126 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.1be3804f96ff0532:core.Destroy.Core", scope: null, file: !112, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !113, retainedNodes: !129)
|
||||
// CHECK:STDOUT: !127 = !DILocalVariable(arg: 1, scope: !126, type: !22)
|
||||
// CHECK:STDOUT: !128 = !DILocation(line: 5, column: 1, scope: !126)
|
||||
// CHECK:STDOUT: !129 = !{!127}
|
||||
// CHECK:STDOUT: !130 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.1be3804f96ff0532:core.Destroy.Core", scope: null, file: !112, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !113, retainedNodes: !133)
|
||||
// CHECK:STDOUT: !131 = !DILocalVariable(arg: 1, scope: !130, type: !22)
|
||||
// CHECK:STDOUT: !132 = !DILocation(line: 5, column: 1, scope: !130)
|
||||
// CHECK:STDOUT: !133 = !{!131}
|
||||
// CHECK:STDOUT: !134 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.StaticA.Main", scope: null, file: !112, line: 6, type: !115, spFlags: DISPFlagDefinition, unit: !113)
|
||||
// CHECK:STDOUT: !135 = !DILocation(line: 6, column: 3, scope: !134)
|
||||
// CHECK:STDOUT: !136 = distinct !DISubprogram(name: "CallCallF", linkageName: "_CCallCallF.Main", scope: null, file: !112, line: 15, type: !115, spFlags: DISPFlagDefinition, unit: !113)
|
||||
// CHECK:STDOUT: !137 = !DILocation(line: 15, column: 18, scope: !136)
|
||||
// CHECK:STDOUT: !138 = !DILocation(line: 15, column: 1, scope: !136)
|
||||
// CHECK:STDOUT:
|
||||
|
||||
+116
-81
@@ -71,6 +71,7 @@ fn Packed(n: i32) {
|
||||
// CHECK:STDOUT: %.loc25.n = getelementptr inbounds nuw [4 x i8], ptr %a.var, i32 0, i32 0, !dbg !47
|
||||
// CHECK:STDOUT: store i32 %n, ptr %.loc25.n, align 4, !dbg !47
|
||||
// CHECK:STDOUT: call void @_Z4TakeI16NaturallyAlignedEvRT_(ptr %a.var), !dbg !51
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.89af5f7a0692dfe8:core.Destroy.Core"(ptr %a.var), !dbg !45
|
||||
// CHECK:STDOUT: ret void, !dbg !52
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -78,8 +79,8 @@ fn Packed(n: i32) {
|
||||
// CHECK:STDOUT: define internal void @_ZN16NaturallyAlignedC1Ev.carbon_thunk.(ptr noundef %return) #1 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !106
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !106
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !118
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !118
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -93,84 +94,104 @@ fn Packed(n: i32) {
|
||||
// CHECK:STDOUT: declare void @_Z4TakeI16NaturallyAlignedEvRT_(ptr noundef nonnull align 4 dereferenceable(4)) #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CExtraAlignment.Main(i32 %n) #0 !dbg !57 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.89af5f7a0692dfe8:core.Destroy.Core"(ptr %self) #0 !dbg !57 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %a.var = alloca [16 x i8], align 16, !dbg !60
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !60
|
||||
// CHECK:STDOUT: call void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.34933c1c343bd645"(ptr %a.var), !dbg !60
|
||||
// CHECK:STDOUT: %.loc33.n = getelementptr inbounds nuw [16 x i8], ptr %a.var, i32 0, i32 0, !dbg !62
|
||||
// CHECK:STDOUT: store i32 %n, ptr %.loc33.n, align 4, !dbg !62
|
||||
// CHECK:STDOUT: call void @_Z4TakeI14ExtraAlignmentEvRT_(ptr %a.var), !dbg !66
|
||||
// CHECK:STDOUT: ret void, !dbg !67
|
||||
// CHECK:STDOUT: ret void, !dbg !59
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CExtraAlignment.Main(i32 %n) #0 !dbg !61 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %a.var = alloca [16 x i8], align 16, !dbg !64
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !64
|
||||
// CHECK:STDOUT: call void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.34933c1c343bd645"(ptr %a.var), !dbg !64
|
||||
// CHECK:STDOUT: %.loc33.n = getelementptr inbounds nuw [16 x i8], ptr %a.var, i32 0, i32 0, !dbg !66
|
||||
// CHECK:STDOUT: store i32 %n, ptr %.loc33.n, align 4, !dbg !66
|
||||
// CHECK:STDOUT: call void @_Z4TakeI14ExtraAlignmentEvRT_(ptr %a.var), !dbg !70
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.77c39a3d53f40ae2:core.Destroy.Core"(ptr %a.var), !dbg !64
|
||||
// CHECK:STDOUT: ret void, !dbg !71
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
// CHECK:STDOUT: define internal void @_ZN14ExtraAlignmentC1Ev.carbon_thunk.(ptr noundef %return) #1 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !108
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !108
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !120
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !120
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp:thunk:Default.52e7708693d29223.Core:ExtraAlignment.Cpp"(ptr sret([16 x i8]) %return) #2 !dbg !69 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp:thunk:Default.52e7708693d29223.Core:ExtraAlignment.Cpp"(ptr sret([16 x i8]) %return) #2 !dbg !73 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN14ExtraAlignmentC1Ev.carbon_thunk.(ptr %return), !dbg !71
|
||||
// CHECK:STDOUT: ret void, !dbg !71
|
||||
// CHECK:STDOUT: call void @_ZN14ExtraAlignmentC1Ev.carbon_thunk.(ptr %return), !dbg !75
|
||||
// CHECK:STDOUT: ret void, !dbg !75
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_Z4TakeI14ExtraAlignmentEvRT_(ptr noundef nonnull align 16 dereferenceable(16)) #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPacked.Main(i32 %n) #0 !dbg !72 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.77c39a3d53f40ae2:core.Destroy.Core"(ptr %self) #0 !dbg !76 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %a.var = alloca [4 x i8], align 1, !dbg !75
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !75
|
||||
// CHECK:STDOUT: call void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.3e10857902c69c1a"(ptr %a.var), !dbg !75
|
||||
// CHECK:STDOUT: %.loc42.n = getelementptr inbounds nuw [4 x i8], ptr %a.var, i32 0, i32 0, !dbg !77
|
||||
// CHECK:STDOUT: store i32 %n, ptr %.loc42.n, align 4, !dbg !77
|
||||
// CHECK:STDOUT: call void @_Z4TakeI6PackedEvRT_(ptr %a.var), !dbg !81
|
||||
// CHECK:STDOUT: ret void, !dbg !82
|
||||
// CHECK:STDOUT: ret void, !dbg !78
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPacked.Main(i32 %n) #0 !dbg !80 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %a.var = alloca [4 x i8], align 1, !dbg !83
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !83
|
||||
// CHECK:STDOUT: call void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.3e10857902c69c1a"(ptr %a.var), !dbg !83
|
||||
// CHECK:STDOUT: %.loc42.n = getelementptr inbounds nuw [4 x i8], ptr %a.var, i32 0, i32 0, !dbg !85
|
||||
// CHECK:STDOUT: store i32 %n, ptr %.loc42.n, align 4, !dbg !85
|
||||
// CHECK:STDOUT: call void @_Z4TakeI6PackedEvRT_(ptr %a.var), !dbg !89
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.00b787a687567d9a:core.Destroy.Core"(ptr %a.var), !dbg !83
|
||||
// CHECK:STDOUT: ret void, !dbg !90
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
// CHECK:STDOUT: define internal void @_ZN6PackedC1Ev.carbon_thunk.(ptr noundef %return) #1 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !122
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !122
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp:thunk:Default.ca2b917a39954a06.Core:Packed.Cpp"(ptr sret([4 x i8]) %return) #2 !dbg !84 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp:thunk:Default.ca2b917a39954a06.Core:Packed.Cpp"(ptr sret([4 x i8]) %return) #2 !dbg !92 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN6PackedC1Ev.carbon_thunk.(ptr %return), !dbg !86
|
||||
// CHECK:STDOUT: ret void, !dbg !86
|
||||
// CHECK:STDOUT: call void @_ZN6PackedC1Ev.carbon_thunk.(ptr %return), !dbg !94
|
||||
// CHECK:STDOUT: ret void, !dbg !94
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_Z4TakeI6PackedEvRT_(ptr noundef nonnull align 1 dereferenceable(4)) #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.00b787a687567d9a:core.Destroy.Core"(ptr %self) #0 !dbg !95 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !97
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #4
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define linkonce_odr void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.d4cda66b3640b619"(ptr sret([4 x i8]) %return) #0 !dbg !87 {
|
||||
// CHECK:STDOUT: call void @"_COp:thunk:Default.c846b89dd79c7366.Core:NaturallyAligned.Cpp"(ptr %return), !dbg !90
|
||||
// CHECK:STDOUT: ret void, !dbg !91
|
||||
// CHECK:STDOUT: define linkonce_odr void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.d4cda66b3640b619"(ptr sret([4 x i8]) %return) #0 !dbg !99 {
|
||||
// CHECK:STDOUT: call void @"_COp:thunk:Default.c846b89dd79c7366.Core:NaturallyAligned.Cpp"(ptr %return), !dbg !102
|
||||
// CHECK:STDOUT: ret void, !dbg !103
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define linkonce_odr void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.34933c1c343bd645"(ptr sret([16 x i8]) %return) #0 !dbg !92 {
|
||||
// CHECK:STDOUT: call void @"_COp:thunk:Default.52e7708693d29223.Core:ExtraAlignment.Cpp"(ptr %return), !dbg !95
|
||||
// CHECK:STDOUT: ret void, !dbg !96
|
||||
// CHECK:STDOUT: define linkonce_odr void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.34933c1c343bd645"(ptr sret([16 x i8]) %return) #0 !dbg !104 {
|
||||
// CHECK:STDOUT: call void @"_COp:thunk:Default.52e7708693d29223.Core:ExtraAlignment.Cpp"(ptr %return), !dbg !107
|
||||
// CHECK:STDOUT: ret void, !dbg !108
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define linkonce_odr void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.3e10857902c69c1a"(ptr sret([4 x i8]) %return) #0 !dbg !97 {
|
||||
// CHECK:STDOUT: call void @"_COp:thunk:Default.ca2b917a39954a06.Core:Packed.Cpp"(ptr %return), !dbg !100
|
||||
// CHECK:STDOUT: ret void, !dbg !101
|
||||
// CHECK:STDOUT: define linkonce_odr void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.3e10857902c69c1a"(ptr sret([4 x i8]) %return) #0 !dbg !109 {
|
||||
// CHECK:STDOUT: call void @"_COp:thunk:Default.ca2b917a39954a06.Core:Packed.Cpp"(ptr %return), !dbg !112
|
||||
// CHECK:STDOUT: ret void, !dbg !113
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; uselistorder directives
|
||||
@@ -183,8 +204,8 @@ fn Packed(n: i32) {
|
||||
// CHECK:STDOUT: attributes #4 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!33}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!111, !112, !113, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!116}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!123, !124, !125, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!128}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -195,6 +216,8 @@ fn Packed(n: i32) {
|
||||
// CHECK:STDOUT: !35 = !{null, !34}
|
||||
// CHECK:STDOUT: !36 = !DISubroutineType(types: !35)
|
||||
// CHECK:STDOUT: !37 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
|
||||
// CHECK:STDOUT: !38 = !{null, !37}
|
||||
// CHECK:STDOUT: !39 = !DISubroutineType(types: !38)
|
||||
// CHECK:STDOUT: !40 = !{!37}
|
||||
// CHECK:STDOUT: !41 = !DISubroutineType(types: !40)
|
||||
// CHECK:STDOUT: !42 = distinct !DISubprogram(name: "NaturallyAligned", linkageName: "_CNaturallyAligned.Main", scope: null, file: !32, line: 23, type: !36, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !53)
|
||||
@@ -206,46 +229,58 @@ fn Packed(n: i32) {
|
||||
// CHECK:STDOUT: !53 = !{!43}
|
||||
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.c846b89dd79c7366.Core:NaturallyAligned.Cpp", scope: null, file: !32, line: 7, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !56 = !DILocation(line: 7, column: 8, scope: !54)
|
||||
// CHECK:STDOUT: !57 = distinct !DISubprogram(name: "ExtraAlignment", linkageName: "_CExtraAlignment.Main", scope: null, file: !32, line: 29, type: !36, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !68)
|
||||
// CHECK:STDOUT: !58 = !DILocalVariable(arg: 1, scope: !57, type: !34)
|
||||
// CHECK:STDOUT: !60 = !DILocation(line: 30, column: 3, scope: !57)
|
||||
// CHECK:STDOUT: !62 = !DILocation(line: 33, column: 3, scope: !57)
|
||||
// CHECK:STDOUT: !66 = !DILocation(line: 34, column: 3, scope: !57)
|
||||
// CHECK:STDOUT: !67 = !DILocation(line: 29, column: 1, scope: !57)
|
||||
// CHECK:STDOUT: !68 = !{!58}
|
||||
// CHECK:STDOUT: !69 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.52e7708693d29223.Core:ExtraAlignment.Cpp", scope: null, file: !32, line: 11, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !71 = !DILocation(line: 11, column: 20, scope: !69)
|
||||
// CHECK:STDOUT: !72 = distinct !DISubprogram(name: "Packed", linkageName: "_CPacked.Main", scope: null, file: !32, line: 37, type: !36, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !83)
|
||||
// CHECK:STDOUT: !73 = !DILocalVariable(arg: 1, scope: !72, type: !34)
|
||||
// CHECK:STDOUT: !75 = !DILocation(line: 38, column: 3, scope: !72)
|
||||
// CHECK:STDOUT: !77 = !DILocation(line: 42, column: 3, scope: !72)
|
||||
// CHECK:STDOUT: !81 = !DILocation(line: 43, column: 3, scope: !72)
|
||||
// CHECK:STDOUT: !82 = !DILocation(line: 37, column: 1, scope: !72)
|
||||
// CHECK:STDOUT: !83 = !{!73}
|
||||
// CHECK:STDOUT: !84 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.ca2b917a39954a06.Core:Packed.Cpp", scope: null, file: !32, line: 15, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !86 = !DILocation(line: 15, column: 32, scope: !84)
|
||||
// CHECK:STDOUT: !87 = distinct !DISubprogram(name: "Op", linkageName: "_COp.51f3fb62cb986374:DefaultOrUnformed.Core.d4cda66b3640b619", scope: null, file: !26, line: 9, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !90 = !DILocation(line: 9, column: 28, scope: !87)
|
||||
// CHECK:STDOUT: !91 = !DILocation(line: 9, column: 21, scope: !87)
|
||||
// CHECK:STDOUT: !92 = distinct !DISubprogram(name: "Op", linkageName: "_COp.51f3fb62cb986374:DefaultOrUnformed.Core.34933c1c343bd645", scope: null, file: !26, line: 9, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !95 = !DILocation(line: 9, column: 28, scope: !92)
|
||||
// CHECK:STDOUT: !96 = !DILocation(line: 9, column: 21, scope: !92)
|
||||
// CHECK:STDOUT: !97 = distinct !DISubprogram(name: "Op", linkageName: "_COp.51f3fb62cb986374:DefaultOrUnformed.Core.3e10857902c69c1a", scope: null, file: !26, line: 9, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !100 = !DILocation(line: 9, column: 28, scope: !97)
|
||||
// CHECK:STDOUT: !101 = !DILocation(line: 9, column: 21, scope: !97)
|
||||
// CHECK:STDOUT: !102 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !103 = !{!"omnipotent char", !102, i64 0}
|
||||
// CHECK:STDOUT: !104 = !{!"any pointer", !103, i64 0}
|
||||
// CHECK:STDOUT: !105 = !{!"p1 _ZTS16NaturallyAligned", !104, i64 0}
|
||||
// CHECK:STDOUT: !106 = !{!105, !105, i64 0}
|
||||
// CHECK:STDOUT: !107 = !{!"p1 _ZTS14ExtraAlignment", !104, i64 0}
|
||||
// CHECK:STDOUT: !108 = !{!107, !107, i64 0}
|
||||
// CHECK:STDOUT: !109 = !{!"p1 _ZTS6Packed", !104, i64 0}
|
||||
// CHECK:STDOUT: !110 = !{!109, !109, i64 0}
|
||||
// CHECK:STDOUT: !111 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !112 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !113 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !114 = !{!"int", !103, i64 0}
|
||||
// CHECK:STDOUT: !115 = !{!"__libc_errno", !114, i64 0}
|
||||
// CHECK:STDOUT: !116 = !{!115, !114, i64 0}
|
||||
// CHECK:STDOUT: !57 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.89af5f7a0692dfe8:core.Destroy.Core", scope: null, file: !32, line: 24, type: !39, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !60)
|
||||
// CHECK:STDOUT: !58 = !DILocalVariable(arg: 1, scope: !57, type: !37)
|
||||
// CHECK:STDOUT: !59 = !DILocation(line: 24, column: 3, scope: !57)
|
||||
// CHECK:STDOUT: !60 = !{!58}
|
||||
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "ExtraAlignment", linkageName: "_CExtraAlignment.Main", scope: null, file: !32, line: 29, type: !36, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !72)
|
||||
// CHECK:STDOUT: !62 = !DILocalVariable(arg: 1, scope: !61, type: !34)
|
||||
// CHECK:STDOUT: !64 = !DILocation(line: 30, column: 3, scope: !61)
|
||||
// CHECK:STDOUT: !66 = !DILocation(line: 33, column: 3, scope: !61)
|
||||
// CHECK:STDOUT: !70 = !DILocation(line: 34, column: 3, scope: !61)
|
||||
// CHECK:STDOUT: !71 = !DILocation(line: 29, column: 1, scope: !61)
|
||||
// CHECK:STDOUT: !72 = !{!62}
|
||||
// CHECK:STDOUT: !73 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.52e7708693d29223.Core:ExtraAlignment.Cpp", scope: null, file: !32, line: 11, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !75 = !DILocation(line: 11, column: 20, scope: !73)
|
||||
// CHECK:STDOUT: !76 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.77c39a3d53f40ae2:core.Destroy.Core", scope: null, file: !32, line: 30, type: !39, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !79)
|
||||
// CHECK:STDOUT: !77 = !DILocalVariable(arg: 1, scope: !76, type: !37)
|
||||
// CHECK:STDOUT: !78 = !DILocation(line: 30, column: 3, scope: !76)
|
||||
// CHECK:STDOUT: !79 = !{!77}
|
||||
// CHECK:STDOUT: !80 = distinct !DISubprogram(name: "Packed", linkageName: "_CPacked.Main", scope: null, file: !32, line: 37, type: !36, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !91)
|
||||
// CHECK:STDOUT: !81 = !DILocalVariable(arg: 1, scope: !80, type: !34)
|
||||
// CHECK:STDOUT: !83 = !DILocation(line: 38, column: 3, scope: !80)
|
||||
// CHECK:STDOUT: !85 = !DILocation(line: 42, column: 3, scope: !80)
|
||||
// CHECK:STDOUT: !89 = !DILocation(line: 43, column: 3, scope: !80)
|
||||
// CHECK:STDOUT: !90 = !DILocation(line: 37, column: 1, scope: !80)
|
||||
// CHECK:STDOUT: !91 = !{!81}
|
||||
// CHECK:STDOUT: !92 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.ca2b917a39954a06.Core:Packed.Cpp", scope: null, file: !32, line: 15, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !94 = !DILocation(line: 15, column: 32, scope: !92)
|
||||
// CHECK:STDOUT: !95 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.00b787a687567d9a:core.Destroy.Core", scope: null, file: !32, line: 38, type: !39, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !98)
|
||||
// CHECK:STDOUT: !96 = !DILocalVariable(arg: 1, scope: !95, type: !37)
|
||||
// CHECK:STDOUT: !97 = !DILocation(line: 38, column: 3, scope: !95)
|
||||
// CHECK:STDOUT: !98 = !{!96}
|
||||
// CHECK:STDOUT: !99 = distinct !DISubprogram(name: "Op", linkageName: "_COp.51f3fb62cb986374:DefaultOrUnformed.Core.d4cda66b3640b619", scope: null, file: !26, line: 9, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !102 = !DILocation(line: 9, column: 28, scope: !99)
|
||||
// CHECK:STDOUT: !103 = !DILocation(line: 9, column: 21, scope: !99)
|
||||
// CHECK:STDOUT: !104 = distinct !DISubprogram(name: "Op", linkageName: "_COp.51f3fb62cb986374:DefaultOrUnformed.Core.34933c1c343bd645", scope: null, file: !26, line: 9, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !107 = !DILocation(line: 9, column: 28, scope: !104)
|
||||
// CHECK:STDOUT: !108 = !DILocation(line: 9, column: 21, scope: !104)
|
||||
// CHECK:STDOUT: !109 = distinct !DISubprogram(name: "Op", linkageName: "_COp.51f3fb62cb986374:DefaultOrUnformed.Core.3e10857902c69c1a", scope: null, file: !26, line: 9, type: !41, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !112 = !DILocation(line: 9, column: 28, scope: !109)
|
||||
// CHECK:STDOUT: !113 = !DILocation(line: 9, column: 21, scope: !109)
|
||||
// CHECK:STDOUT: !114 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !115 = !{!"omnipotent char", !114, i64 0}
|
||||
// CHECK:STDOUT: !116 = !{!"any pointer", !115, i64 0}
|
||||
// CHECK:STDOUT: !117 = !{!"p1 _ZTS16NaturallyAligned", !116, i64 0}
|
||||
// CHECK:STDOUT: !118 = !{!117, !117, i64 0}
|
||||
// CHECK:STDOUT: !119 = !{!"p1 _ZTS14ExtraAlignment", !116, i64 0}
|
||||
// CHECK:STDOUT: !120 = !{!119, !119, i64 0}
|
||||
// CHECK:STDOUT: !121 = !{!"p1 _ZTS6Packed", !116, i64 0}
|
||||
// CHECK:STDOUT: !122 = !{!121, !121, i64 0}
|
||||
// CHECK:STDOUT: !123 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !124 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !125 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !126 = !{!"int", !115, i64 0}
|
||||
// CHECK:STDOUT: !127 = !{!"__libc_errno", !126, i64 0}
|
||||
// CHECK:STDOUT: !128 = !{!127, !126, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
+469
-374
File diff suppressed because it is too large
Load Diff
+199
-140
@@ -90,7 +90,7 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: %a.var = alloca [4 x i8], align 4, !dbg !29
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !29
|
||||
// CHECK:STDOUT: call void @_ZNK1Bcv1AEv.carbon_thunk._(ptr %b, ptr %a.var), !dbg !29
|
||||
// CHECK:STDOUT: call void @_ZN1AD1Ev(ptr %a.var), !dbg !29
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.f2cd4feee22137a3:core.Destroy.Core"(ptr %a.var), !dbg !29
|
||||
// CHECK:STDOUT: ret void, !dbg !32
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -99,10 +99,10 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !46
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !48
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !48
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %this.addr, align 8, !tbaa !46, !nonnull !50
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !50
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !52
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !52
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %this.addr, align 8, !tbaa !50, !nonnull !54
|
||||
// CHECK:STDOUT: call void @_ZNK1Bcv1AEv(ptr dead_on_unwind writable sret(%struct.A) align 4 %0, ptr noundef nonnull align 1 dereferenceable(1) %1)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
@@ -111,13 +111,20 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: declare void @_ZN1AD1Ev(ptr noundef nonnull align 4 dead_on_return(4) dereferenceable(4)) unnamed_addr #2
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CConvertToValue.Main(ptr %b) #0 !dbg !34 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.f2cd4feee22137a3:core.Destroy.Core"(ptr %self) #0 !dbg !34 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc20_25.1.temp = alloca [4 x i8], align 4, !dbg !37
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_25.1.temp), !dbg !37
|
||||
// CHECK:STDOUT: call void @_ZNK1Bcv1AEv.carbon_thunk._(ptr %b, ptr %.loc20_25.1.temp), !dbg !37
|
||||
// CHECK:STDOUT: call void @_ZN1AD1Ev(ptr %.loc20_25.1.temp), !dbg !37
|
||||
// CHECK:STDOUT: ret void, !dbg !40
|
||||
// CHECK:STDOUT: call void @_ZN1AD1Ev(ptr %self), !dbg !36
|
||||
// CHECK:STDOUT: ret void, !dbg !36
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CConvertToValue.Main(ptr %b) #0 !dbg !38 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc20_25.1.temp = alloca [4 x i8], align 4, !dbg !41
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_25.1.temp), !dbg !41
|
||||
// CHECK:STDOUT: call void @_ZNK1Bcv1AEv.carbon_thunk._(ptr %b, ptr %.loc20_25.1.temp), !dbg !41
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.f2cd4feee22137a3:core.Destroy.Core"(ptr %.loc20_25.1.temp), !dbg !41
|
||||
// CHECK:STDOUT: ret void, !dbg !44
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
@@ -135,8 +142,8 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: attributes #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!19}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!53, !54, !55, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!57}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!57, !58, !59, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!61}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -150,25 +157,29 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: !29 = !DILocation(line: 16, column: 3, scope: !26)
|
||||
// CHECK:STDOUT: !32 = !DILocation(line: 15, column: 1, scope: !26)
|
||||
// CHECK:STDOUT: !33 = !{!27}
|
||||
// CHECK:STDOUT: !34 = distinct !DISubprogram(name: "ConvertToValue", linkageName: "_CConvertToValue.Main", scope: null, file: !18, line: 19, type: !23, spFlags: DISPFlagDefinition, unit: !19, retainedNodes: !41)
|
||||
// CHECK:STDOUT: !34 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.f2cd4feee22137a3:core.Destroy.Core", scope: null, file: !18, line: 16, type: !23, spFlags: DISPFlagDefinition, unit: !19, retainedNodes: !37)
|
||||
// CHECK:STDOUT: !35 = !DILocalVariable(arg: 1, scope: !34, type: !21)
|
||||
// CHECK:STDOUT: !37 = !DILocation(line: 20, column: 25, scope: !34)
|
||||
// CHECK:STDOUT: !40 = !DILocation(line: 19, column: 1, scope: !34)
|
||||
// CHECK:STDOUT: !41 = !{!35}
|
||||
// CHECK:STDOUT: !42 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !43 = !{!"omnipotent char", !42, i64 0}
|
||||
// CHECK:STDOUT: !44 = !{!"any pointer", !43, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{!"p1 _ZTS1B", !44, i64 0}
|
||||
// CHECK:STDOUT: !46 = !{!45, !45, i64 0}
|
||||
// CHECK:STDOUT: !47 = !{!"p1 _ZTS1A", !44, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{!47, !47, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{}
|
||||
// CHECK:STDOUT: !51 = !{!"int", !43, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !54 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !55 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !56 = !{!"__libc_errno", !51, i64 0}
|
||||
// CHECK:STDOUT: !57 = !{!56, !51, i64 0}
|
||||
// CHECK:STDOUT: !36 = !DILocation(line: 16, column: 3, scope: !34)
|
||||
// CHECK:STDOUT: !37 = !{!35}
|
||||
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "ConvertToValue", linkageName: "_CConvertToValue.Main", scope: null, file: !18, line: 19, type: !23, spFlags: DISPFlagDefinition, unit: !19, retainedNodes: !45)
|
||||
// CHECK:STDOUT: !39 = !DILocalVariable(arg: 1, scope: !38, type: !21)
|
||||
// CHECK:STDOUT: !41 = !DILocation(line: 20, column: 25, scope: !38)
|
||||
// CHECK:STDOUT: !44 = !DILocation(line: 19, column: 1, scope: !38)
|
||||
// CHECK:STDOUT: !45 = !{!39}
|
||||
// CHECK:STDOUT: !46 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !47 = !{!"omnipotent char", !46, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{!"any pointer", !47, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{!"p1 _ZTS1B", !48, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{!49, !49, i64 0}
|
||||
// CHECK:STDOUT: !51 = !{!"p1 _ZTS1A", !48, i64 0}
|
||||
// CHECK:STDOUT: !52 = !{!51, !51, i64 0}
|
||||
// CHECK:STDOUT: !54 = !{}
|
||||
// CHECK:STDOUT: !55 = !{!"int", !47, i64 0}
|
||||
// CHECK:STDOUT: !57 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !58 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !59 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !60 = !{!"__libc_errno", !55, i64 0}
|
||||
// CHECK:STDOUT: !61 = !{!60, !55, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'class_to_enum.carbon'
|
||||
@@ -177,15 +188,17 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CConvertToVar.Main(ptr %b) #0 !dbg !61 {
|
||||
// CHECK:STDOUT: define void @_CConvertToVar.Main(ptr %b) #0 !dbg !67 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %s.var = alloca i16, align 2, !dbg !64
|
||||
// CHECK:STDOUT: %i.var = alloca i16, align 2, !dbg !67
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %s.var), !dbg !64
|
||||
// CHECK:STDOUT: call void @_ZNK5EnumBcv1SEv.carbon_thunk._(ptr %b, ptr %s.var), !dbg !64
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %i.var), !dbg !67
|
||||
// CHECK:STDOUT: call void @_ZNK5EnumBcv1IEv.carbon_thunk._(ptr %b, ptr %i.var), !dbg !67
|
||||
// CHECK:STDOUT: ret void, !dbg !70
|
||||
// CHECK:STDOUT: %s.var = alloca i16, align 2, !dbg !70
|
||||
// CHECK:STDOUT: %i.var = alloca i16, align 2, !dbg !73
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %s.var), !dbg !70
|
||||
// CHECK:STDOUT: call void @_ZNK5EnumBcv1SEv.carbon_thunk._(ptr %b, ptr %s.var), !dbg !70
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %i.var), !dbg !73
|
||||
// CHECK:STDOUT: call void @_ZNK5EnumBcv1IEv.carbon_thunk._(ptr %b, ptr %i.var), !dbg !73
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.93ce72f55a28222b:core.Destroy.Core"(ptr %i.var), !dbg !73
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.7c9bfa05445fab48:core.Destroy.Core"(ptr %s.var), !dbg !70
|
||||
// CHECK:STDOUT: ret void, !dbg !76
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
|
||||
@@ -193,12 +206,12 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !84
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !85
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !85
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %this.addr, align 8, !tbaa !84, !nonnull !50
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !98
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !99
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !99
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %this.addr, align 8, !tbaa !98, !nonnull !54
|
||||
// CHECK:STDOUT: %call = call noundef signext i16 @_ZNK5EnumBcv1SEv(ptr noundef nonnull align 1 dereferenceable(1) %1)
|
||||
// CHECK:STDOUT: store i16 %call, ptr %0, align 2, !tbaa !88
|
||||
// CHECK:STDOUT: store i16 %call, ptr %0, align 2, !tbaa !102
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -207,27 +220,41 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !84
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !85
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !85
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %this.addr, align 8, !tbaa !84, !nonnull !50
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !98
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !99
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !99
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %this.addr, align 8, !tbaa !98, !nonnull !54
|
||||
// CHECK:STDOUT: %call = call noundef signext i16 @_ZNK5EnumBcv1IEv(ptr noundef nonnull align 1 dereferenceable(1) %1)
|
||||
// CHECK:STDOUT: store i16 %call, ptr %0, align 2, !tbaa !90
|
||||
// CHECK:STDOUT: store i16 %call, ptr %0, align 2, !tbaa !104
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CConvertToValue.Main(ptr %b) #0 !dbg !72 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.93ce72f55a28222b:core.Destroy.Core"(ptr %self) #0 !dbg !78 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc20_25.1.temp = alloca i16, align 2, !dbg !75
|
||||
// CHECK:STDOUT: %.loc21_25.1.temp = alloca i16, align 2, !dbg !78
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_25.1.temp), !dbg !75
|
||||
// CHECK:STDOUT: call void @_ZNK5EnumBcv1SEv.carbon_thunk._(ptr %b, ptr %.loc20_25.1.temp), !dbg !75
|
||||
// CHECK:STDOUT: %.loc20_25.5 = load i16, ptr %.loc20_25.1.temp, align 2, !dbg !75
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc21_25.1.temp), !dbg !78
|
||||
// CHECK:STDOUT: call void @_ZNK5EnumBcv1IEv.carbon_thunk._(ptr %b, ptr %.loc21_25.1.temp), !dbg !78
|
||||
// CHECK:STDOUT: %.loc21_25.5 = load i16, ptr %.loc21_25.1.temp, align 2, !dbg !78
|
||||
// CHECK:STDOUT: ret void, !dbg !81
|
||||
// CHECK:STDOUT: ret void, !dbg !80
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.7c9bfa05445fab48:core.Destroy.Core"(ptr %self) #0 !dbg !82 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !84
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CConvertToValue.Main(ptr %b) #0 !dbg !86 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc20_25.1.temp = alloca i16, align 2, !dbg !89
|
||||
// CHECK:STDOUT: %.loc21_25.1.temp = alloca i16, align 2, !dbg !92
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_25.1.temp), !dbg !89
|
||||
// CHECK:STDOUT: call void @_ZNK5EnumBcv1SEv.carbon_thunk._(ptr %b, ptr %.loc20_25.1.temp), !dbg !89
|
||||
// CHECK:STDOUT: %.loc20_25.5 = load i16, ptr %.loc20_25.1.temp, align 2, !dbg !89
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc21_25.1.temp), !dbg !92
|
||||
// CHECK:STDOUT: call void @_ZNK5EnumBcv1IEv.carbon_thunk._(ptr %b, ptr %.loc21_25.1.temp), !dbg !92
|
||||
// CHECK:STDOUT: %.loc21_25.5 = load i16, ptr %.loc21_25.1.temp, align 2, !dbg !92
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.93ce72f55a28222b:core.Destroy.Core"(ptr %.loc21_25.1.temp), !dbg !92
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.7c9bfa05445fab48:core.Destroy.Core"(ptr %.loc20_25.1.temp), !dbg !89
|
||||
// CHECK:STDOUT: ret void, !dbg !95
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
@@ -245,46 +272,57 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: attributes #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
|
||||
// CHECK:STDOUT: attributes #3 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!59}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!53, !54, !55, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!57}
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!63}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!57, !58, !59, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!61}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
// CHECK:STDOUT: !21 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
|
||||
// CHECK:STDOUT: !22 = !{null, !21}
|
||||
// CHECK:STDOUT: !23 = !DISubroutineType(types: !22)
|
||||
// CHECK:STDOUT: !42 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !43 = !{!"omnipotent char", !42, i64 0}
|
||||
// CHECK:STDOUT: !44 = !{!"any pointer", !43, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{}
|
||||
// CHECK:STDOUT: !51 = !{!"int", !43, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !54 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !55 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !56 = !{!"__libc_errno", !51, i64 0}
|
||||
// CHECK:STDOUT: !57 = !{!56, !51, i64 0}
|
||||
// CHECK:STDOUT: !58 = !DIFile(filename: "class_to_enum.carbon", directory: "")
|
||||
// CHECK:STDOUT: !59 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !58, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "ConvertToVar", linkageName: "_CConvertToVar.Main", scope: null, file: !58, line: 14, type: !23, spFlags: DISPFlagDefinition, unit: !59, retainedNodes: !71)
|
||||
// CHECK:STDOUT: !62 = !DILocalVariable(arg: 1, scope: !61, type: !21)
|
||||
// CHECK:STDOUT: !64 = !DILocation(line: 15, column: 3, scope: !61)
|
||||
// CHECK:STDOUT: !67 = !DILocation(line: 16, column: 3, scope: !61)
|
||||
// CHECK:STDOUT: !70 = !DILocation(line: 14, column: 1, scope: !61)
|
||||
// CHECK:STDOUT: !71 = !{!62}
|
||||
// CHECK:STDOUT: !72 = distinct !DISubprogram(name: "ConvertToValue", linkageName: "_CConvertToValue.Main", scope: null, file: !58, line: 19, type: !23, spFlags: DISPFlagDefinition, unit: !59, retainedNodes: !82)
|
||||
// CHECK:STDOUT: !73 = !DILocalVariable(arg: 1, scope: !72, type: !21)
|
||||
// CHECK:STDOUT: !75 = !DILocation(line: 20, column: 25, scope: !72)
|
||||
// CHECK:STDOUT: !78 = !DILocation(line: 21, column: 25, scope: !72)
|
||||
// CHECK:STDOUT: !81 = !DILocation(line: 19, column: 1, scope: !72)
|
||||
// CHECK:STDOUT: !82 = !{!73}
|
||||
// CHECK:STDOUT: !83 = !{!"p1 _ZTS5EnumB", !44, i64 0}
|
||||
// CHECK:STDOUT: !84 = !{!83, !83, i64 0}
|
||||
// CHECK:STDOUT: !85 = !{!44, !44, i64 0}
|
||||
// CHECK:STDOUT: !86 = !{!"_ZTS1S", !43, i64 0}
|
||||
// CHECK:STDOUT: !88 = !{!86, !86, i64 0}
|
||||
// CHECK:STDOUT: !89 = !{!"_ZTS1I", !43, i64 0}
|
||||
// CHECK:STDOUT: !90 = !{!89, !89, i64 0}
|
||||
// CHECK:STDOUT: !46 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !47 = !{!"omnipotent char", !46, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{!"any pointer", !47, i64 0}
|
||||
// CHECK:STDOUT: !54 = !{}
|
||||
// CHECK:STDOUT: !55 = !{!"int", !47, i64 0}
|
||||
// CHECK:STDOUT: !57 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !58 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !59 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !60 = !{!"__libc_errno", !55, i64 0}
|
||||
// CHECK:STDOUT: !61 = !{!60, !55, i64 0}
|
||||
// CHECK:STDOUT: !62 = !DIFile(filename: "class_to_enum.carbon", directory: "")
|
||||
// CHECK:STDOUT: !63 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !62, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !64 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_signed)
|
||||
// CHECK:STDOUT: !65 = !{null, !64}
|
||||
// CHECK:STDOUT: !66 = !DISubroutineType(types: !65)
|
||||
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "ConvertToVar", linkageName: "_CConvertToVar.Main", scope: null, file: !62, line: 14, type: !23, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !77)
|
||||
// CHECK:STDOUT: !68 = !DILocalVariable(arg: 1, scope: !67, type: !21)
|
||||
// CHECK:STDOUT: !70 = !DILocation(line: 15, column: 3, scope: !67)
|
||||
// CHECK:STDOUT: !73 = !DILocation(line: 16, column: 3, scope: !67)
|
||||
// CHECK:STDOUT: !76 = !DILocation(line: 14, column: 1, scope: !67)
|
||||
// CHECK:STDOUT: !77 = !{!68}
|
||||
// CHECK:STDOUT: !78 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.93ce72f55a28222b:core.Destroy.Core", scope: null, file: !62, line: 16, type: !66, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !81)
|
||||
// CHECK:STDOUT: !79 = !DILocalVariable(arg: 1, scope: !78, type: !64)
|
||||
// CHECK:STDOUT: !80 = !DILocation(line: 16, column: 3, scope: !78)
|
||||
// CHECK:STDOUT: !81 = !{!79}
|
||||
// CHECK:STDOUT: !82 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.7c9bfa05445fab48:core.Destroy.Core", scope: null, file: !62, line: 15, type: !66, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !85)
|
||||
// CHECK:STDOUT: !83 = !DILocalVariable(arg: 1, scope: !82, type: !64)
|
||||
// CHECK:STDOUT: !84 = !DILocation(line: 15, column: 3, scope: !82)
|
||||
// CHECK:STDOUT: !85 = !{!83}
|
||||
// CHECK:STDOUT: !86 = distinct !DISubprogram(name: "ConvertToValue", linkageName: "_CConvertToValue.Main", scope: null, file: !62, line: 19, type: !23, spFlags: DISPFlagDefinition, unit: !63, retainedNodes: !96)
|
||||
// CHECK:STDOUT: !87 = !DILocalVariable(arg: 1, scope: !86, type: !21)
|
||||
// CHECK:STDOUT: !89 = !DILocation(line: 20, column: 25, scope: !86)
|
||||
// CHECK:STDOUT: !92 = !DILocation(line: 21, column: 25, scope: !86)
|
||||
// CHECK:STDOUT: !95 = !DILocation(line: 19, column: 1, scope: !86)
|
||||
// CHECK:STDOUT: !96 = !{!87}
|
||||
// CHECK:STDOUT: !97 = !{!"p1 _ZTS5EnumB", !48, i64 0}
|
||||
// CHECK:STDOUT: !98 = !{!97, !97, i64 0}
|
||||
// CHECK:STDOUT: !99 = !{!48, !48, i64 0}
|
||||
// CHECK:STDOUT: !100 = !{!"_ZTS1S", !47, i64 0}
|
||||
// CHECK:STDOUT: !102 = !{!100, !100, i64 0}
|
||||
// CHECK:STDOUT: !103 = !{!"_ZTS1I", !47, i64 0}
|
||||
// CHECK:STDOUT: !104 = !{!103, !103, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'class_to_int.carbon'
|
||||
@@ -293,37 +331,50 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CConvertToVar.Main(ptr %b) #0 !dbg !97 {
|
||||
// CHECK:STDOUT: define void @_CConvertToVar.Main(ptr %b) #0 !dbg !111 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %a.var = alloca i32, align 4, !dbg !100
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !100
|
||||
// CHECK:STDOUT: %__carbon_thunk.call = call i32 @_ZNK4IntBcviEv.carbon_thunk._(ptr %b), !dbg !100
|
||||
// CHECK:STDOUT: store i32 %__carbon_thunk.call, ptr %a.var, align 4, !dbg !100
|
||||
// CHECK:STDOUT: call void @"_COp.f58524831c37807e:core.Destroy.Core"(ptr %a.var), !dbg !100
|
||||
// CHECK:STDOUT: ret void, !dbg !103
|
||||
// CHECK:STDOUT: %a.var = alloca i32, align 4, !dbg !114
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !114
|
||||
// CHECK:STDOUT: %__carbon_thunk.call = call i32 @_ZNK4IntBcviEv.carbon_thunk._(ptr %b), !dbg !114
|
||||
// CHECK:STDOUT: store i32 %__carbon_thunk.call, ptr %a.var, align 4, !dbg !114
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.f58524831c37807e:core.Destroy.Core"(ptr %a.var), !dbg !114
|
||||
// CHECK:STDOUT: ret void, !dbg !117
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
|
||||
// CHECK:STDOUT: define internal noundef i32 @_ZNK4IntBcviEv.carbon_thunk._(ptr noundef nonnull align 1 dereferenceable(1) %this) #1 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !118
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %this.addr, align 8, !tbaa !118, !nonnull !50
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !140
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %this.addr, align 8, !tbaa !140, !nonnull !54
|
||||
// CHECK:STDOUT: %call = call noundef i32 @_ZNK4IntBcviEv(ptr noundef nonnull align 1 dereferenceable(1) %0)
|
||||
// CHECK:STDOUT: ret i32 %call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.f58524831c37807e:core.Destroy.Core"(ptr %self) #0 !dbg !105 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.6dae29ece9a708c4:core.Destroy.Core"(ptr %self) #0 !dbg !119 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !107
|
||||
// CHECK:STDOUT: ret void, !dbg !121
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CConvertToValue.Main(ptr %b) #0 !dbg !109 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core"(ptr %self) #0 !dbg !123 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %__carbon_thunk.call = call i32 @_ZNK4IntBcviEv.carbon_thunk._(ptr %b), !dbg !112
|
||||
// CHECK:STDOUT: ret void, !dbg !115
|
||||
// CHECK:STDOUT: ret void, !dbg !125
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.f58524831c37807e:core.Destroy.Core"(ptr %self) #0 !dbg !127 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core"(ptr %self), !dbg !129
|
||||
// CHECK:STDOUT: ret void, !dbg !129
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CConvertToValue.Main(ptr %b) #0 !dbg !131 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %__carbon_thunk.call = call i32 @_ZNK4IntBcviEv.carbon_thunk._(ptr %b), !dbg !134
|
||||
// CHECK:STDOUT: ret void, !dbg !137
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
@@ -336,9 +387,9 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: attributes #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
|
||||
// CHECK:STDOUT: attributes #3 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!92}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!53, !54, !55, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!57}
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!106}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!57, !58, !59, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!61}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -346,34 +397,42 @@ fn ConvertToValue(b: Cpp.IntB) {
|
||||
// CHECK:STDOUT: !21 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
|
||||
// CHECK:STDOUT: !22 = !{null, !21}
|
||||
// CHECK:STDOUT: !23 = !DISubroutineType(types: !22)
|
||||
// CHECK:STDOUT: !42 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !43 = !{!"omnipotent char", !42, i64 0}
|
||||
// CHECK:STDOUT: !44 = !{!"any pointer", !43, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{}
|
||||
// CHECK:STDOUT: !51 = !{!"int", !43, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !54 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !55 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !56 = !{!"__libc_errno", !51, i64 0}
|
||||
// CHECK:STDOUT: !57 = !{!56, !51, i64 0}
|
||||
// CHECK:STDOUT: !91 = !DIFile(filename: "class_to_int.carbon", directory: "")
|
||||
// CHECK:STDOUT: !92 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !91, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !95 = !{null, !20}
|
||||
// CHECK:STDOUT: !96 = !DISubroutineType(types: !95)
|
||||
// CHECK:STDOUT: !97 = distinct !DISubprogram(name: "ConvertToVar", linkageName: "_CConvertToVar.Main", scope: null, file: !91, line: 11, type: !23, spFlags: DISPFlagDefinition, unit: !92, retainedNodes: !104)
|
||||
// CHECK:STDOUT: !98 = !DILocalVariable(arg: 1, scope: !97, type: !21)
|
||||
// CHECK:STDOUT: !100 = !DILocation(line: 12, column: 3, scope: !97)
|
||||
// CHECK:STDOUT: !103 = !DILocation(line: 11, column: 1, scope: !97)
|
||||
// CHECK:STDOUT: !104 = !{!98}
|
||||
// CHECK:STDOUT: !105 = distinct !DISubprogram(name: "Op", linkageName: "_COp.f58524831c37807e:core.Destroy.Core", scope: null, file: !91, line: 12, type: !96, spFlags: DISPFlagDefinition, unit: !92, retainedNodes: !108)
|
||||
// CHECK:STDOUT: !106 = !DILocalVariable(arg: 1, scope: !105, type: !20)
|
||||
// CHECK:STDOUT: !107 = !DILocation(line: 12, column: 3, scope: !105)
|
||||
// CHECK:STDOUT: !108 = !{!106}
|
||||
// CHECK:STDOUT: !109 = distinct !DISubprogram(name: "ConvertToValue", linkageName: "_CConvertToValue.Main", scope: null, file: !91, line: 15, type: !23, spFlags: DISPFlagDefinition, unit: !92, retainedNodes: !116)
|
||||
// CHECK:STDOUT: !110 = !DILocalVariable(arg: 1, scope: !109, type: !21)
|
||||
// CHECK:STDOUT: !112 = !DILocation(line: 16, column: 27, scope: !109)
|
||||
// CHECK:STDOUT: !115 = !DILocation(line: 15, column: 1, scope: !109)
|
||||
// CHECK:STDOUT: !116 = !{!110}
|
||||
// CHECK:STDOUT: !117 = !{!"p1 _ZTS4IntB", !44, i64 0}
|
||||
// CHECK:STDOUT: !118 = !{!117, !117, i64 0}
|
||||
// CHECK:STDOUT: !46 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !47 = !{!"omnipotent char", !46, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{!"any pointer", !47, i64 0}
|
||||
// CHECK:STDOUT: !54 = !{}
|
||||
// CHECK:STDOUT: !55 = !{!"int", !47, i64 0}
|
||||
// CHECK:STDOUT: !57 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !58 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !59 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !60 = !{!"__libc_errno", !55, i64 0}
|
||||
// CHECK:STDOUT: !61 = !{!60, !55, i64 0}
|
||||
// CHECK:STDOUT: !105 = !DIFile(filename: "class_to_int.carbon", directory: "")
|
||||
// CHECK:STDOUT: !106 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !105, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !109 = !{null, !20}
|
||||
// CHECK:STDOUT: !110 = !DISubroutineType(types: !109)
|
||||
// CHECK:STDOUT: !111 = distinct !DISubprogram(name: "ConvertToVar", linkageName: "_CConvertToVar.Main", scope: null, file: !105, line: 11, type: !23, spFlags: DISPFlagDefinition, unit: !106, retainedNodes: !118)
|
||||
// CHECK:STDOUT: !112 = !DILocalVariable(arg: 1, scope: !111, type: !21)
|
||||
// CHECK:STDOUT: !114 = !DILocation(line: 12, column: 3, scope: !111)
|
||||
// CHECK:STDOUT: !117 = !DILocation(line: 11, column: 1, scope: !111)
|
||||
// CHECK:STDOUT: !118 = !{!112}
|
||||
// CHECK:STDOUT: !119 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.6dae29ece9a708c4:core.Destroy.Core", scope: null, file: !105, line: 12, type: !110, spFlags: DISPFlagDefinition, unit: !106, retainedNodes: !122)
|
||||
// CHECK:STDOUT: !120 = !DILocalVariable(arg: 1, scope: !119, type: !20)
|
||||
// CHECK:STDOUT: !121 = !DILocation(line: 12, column: 3, scope: !119)
|
||||
// CHECK:STDOUT: !122 = !{!120}
|
||||
// CHECK:STDOUT: !123 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.f58524831c37807e:core.Destroy.Core", scope: null, file: !105, line: 12, type: !110, spFlags: DISPFlagDefinition, unit: !106, retainedNodes: !126)
|
||||
// CHECK:STDOUT: !124 = !DILocalVariable(arg: 1, scope: !123, type: !20)
|
||||
// CHECK:STDOUT: !125 = !DILocation(line: 12, column: 3, scope: !123)
|
||||
// CHECK:STDOUT: !126 = !{!124}
|
||||
// CHECK:STDOUT: !127 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.f58524831c37807e:core.Destroy.Core", scope: null, file: !105, line: 12, type: !110, spFlags: DISPFlagDefinition, unit: !106, retainedNodes: !130)
|
||||
// CHECK:STDOUT: !128 = !DILocalVariable(arg: 1, scope: !127, type: !20)
|
||||
// CHECK:STDOUT: !129 = !DILocation(line: 12, column: 3, scope: !127)
|
||||
// CHECK:STDOUT: !130 = !{!128}
|
||||
// CHECK:STDOUT: !131 = distinct !DISubprogram(name: "ConvertToValue", linkageName: "_CConvertToValue.Main", scope: null, file: !105, line: 15, type: !23, spFlags: DISPFlagDefinition, unit: !106, retainedNodes: !138)
|
||||
// CHECK:STDOUT: !132 = !DILocalVariable(arg: 1, scope: !131, type: !21)
|
||||
// CHECK:STDOUT: !134 = !DILocation(line: 16, column: 27, scope: !131)
|
||||
// CHECK:STDOUT: !137 = !DILocation(line: 15, column: 1, scope: !131)
|
||||
// CHECK:STDOUT: !138 = !{!132}
|
||||
// CHECK:STDOUT: !139 = !{!"p1 _ZTS4IntB", !48, i64 0}
|
||||
// CHECK:STDOUT: !140 = !{!139, !139, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
+183
-144
@@ -123,8 +123,8 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: define internal void @_Z13make_copyablev.carbon_thunk.(ptr noundef %return) #0 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !43
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !43
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !47
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !47
|
||||
// CHECK:STDOUT: call void @_Z13make_copyablev(ptr dead_on_unwind writable sret(%struct.Copyable) align 1 %0)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
@@ -141,8 +141,8 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %agg.tmp = alloca %struct.Copyable, align 1
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !43
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !43
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !47
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !47
|
||||
// CHECK:STDOUT: call void @_ZN8CopyableC1ERKS_(ptr noundef nonnull align 1 dereferenceable(1) %agg.tmp, ptr noundef nonnull align 1 dereferenceable(1) %1)
|
||||
// CHECK:STDOUT: call void @_Z13pass_copyable8Copyable(ptr nofreeobj noundef align 1 dereferenceable(1) %agg.tmp)
|
||||
// CHECK:STDOUT: call void @_ZN8CopyableD1Ev(ptr noundef nonnull align 1 dereferenceable(1) %agg.tmp) #1
|
||||
@@ -156,7 +156,7 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc21_39.1.temp), !dbg !18
|
||||
// CHECK:STDOUT: call void @_Z13make_copyablev.carbon_thunk.(ptr %.loc21_39.1.temp), !dbg !18
|
||||
// CHECK:STDOUT: call void @_Z13pass_copyable8Copyable.carbon_thunk._(ptr %.loc21_39.1.temp), !dbg !19
|
||||
// CHECK:STDOUT: call void @_ZN8CopyableD1Ev(ptr %.loc21_39.1.temp), !dbg !18
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.fd98d268aadcda21:core.Destroy.Core"(ptr %.loc21_39.1.temp), !dbg !18
|
||||
// CHECK:STDOUT: ret void, !dbg !20
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -164,27 +164,34 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: declare void @_ZN8CopyableD1Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassValue.Main(ptr %c) #1 !dbg !21 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.fd98d268aadcda21:core.Destroy.Core"(ptr %self) #1 !dbg !21 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z13pass_copyable8Copyable.carbon_thunk._(ptr %c), !dbg !25
|
||||
// CHECK:STDOUT: ret void, !dbg !26
|
||||
// CHECK:STDOUT: call void @_ZN8CopyableD1Ev(ptr %self), !dbg !23
|
||||
// CHECK:STDOUT: ret void, !dbg !23
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassRef.Main(ptr %c) #1 !dbg !28 {
|
||||
// CHECK:STDOUT: define void @_CPassValue.Main(ptr %c) #1 !dbg !25 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z13pass_copyable8Copyable.carbon_thunk._(ptr %c), !dbg !32
|
||||
// CHECK:STDOUT: ret void, !dbg !33
|
||||
// CHECK:STDOUT: call void @_Z13pass_copyable8Copyable.carbon_thunk._(ptr %c), !dbg !29
|
||||
// CHECK:STDOUT: ret void, !dbg !30
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassRef.Main(ptr %c) #1 !dbg !32 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z13pass_copyable8Copyable.carbon_thunk._(ptr %c), !dbg !36
|
||||
// CHECK:STDOUT: ret void, !dbg !37
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define internal void @_C__global_init.Main() #1 !dbg !35 {
|
||||
// CHECK:STDOUT: define internal void @_C__global_init.Main() #1 !dbg !39 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z13make_copyablev.carbon_thunk.(ptr @_Cc.Main), !dbg !36
|
||||
// CHECK:STDOUT: ret void, !dbg !38
|
||||
// CHECK:STDOUT: call void @_Z13make_copyablev.carbon_thunk.(ptr @_Cc.Main), !dbg !40
|
||||
// CHECK:STDOUT: ret void, !dbg !42
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_Z13make_copyablev(ptr dead_on_unwind writable sret(%struct.Copyable) align 1) #4
|
||||
@@ -193,6 +200,9 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_ZN8CopyableC1ERKS_(ptr noundef nonnull align 1 dereferenceable(1), ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; uselistorder directives
|
||||
// CHECK:STDOUT: uselistorder ptr @_ZN8CopyableD1Ev, { 1, 0 }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: attributes #0 = { alwaysinline mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT: attributes #1 = { nounwind }
|
||||
// CHECK:STDOUT: attributes #2 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
@@ -200,8 +210,8 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: attributes #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!7}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!45, !46, !47, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!50}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!49, !50, !51, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!54}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -219,30 +229,34 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: !18 = !DILocation(line: 21, column: 21, scope: !17)
|
||||
// CHECK:STDOUT: !19 = !DILocation(line: 21, column: 3, scope: !17)
|
||||
// CHECK:STDOUT: !20 = !DILocation(line: 20, column: 1, scope: !17)
|
||||
// CHECK:STDOUT: !21 = distinct !DISubprogram(name: "PassValue", linkageName: "_CPassValue.Main", scope: null, file: !6, line: 24, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !27)
|
||||
// CHECK:STDOUT: !21 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.fd98d268aadcda21:core.Destroy.Core", scope: null, file: !6, line: 21, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !24)
|
||||
// CHECK:STDOUT: !22 = !DILocalVariable(arg: 1, scope: !21, type: !8)
|
||||
// CHECK:STDOUT: !25 = !DILocation(line: 25, column: 3, scope: !21)
|
||||
// CHECK:STDOUT: !26 = !DILocation(line: 24, column: 1, scope: !21)
|
||||
// CHECK:STDOUT: !27 = !{!22}
|
||||
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "PassRef", linkageName: "_CPassRef.Main", scope: null, file: !6, line: 28, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !34)
|
||||
// CHECK:STDOUT: !29 = !DILocalVariable(arg: 1, scope: !28, type: !8)
|
||||
// CHECK:STDOUT: !32 = !DILocation(line: 29, column: 3, scope: !28)
|
||||
// CHECK:STDOUT: !33 = !DILocation(line: 28, column: 1, scope: !28)
|
||||
// CHECK:STDOUT: !34 = !{!29}
|
||||
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !6, type: !12, spFlags: DISPFlagDefinition, unit: !7)
|
||||
// CHECK:STDOUT: !36 = !DILocation(line: 14, column: 23, scope: !35)
|
||||
// CHECK:STDOUT: !38 = !DILocation(line: 0, scope: !35)
|
||||
// CHECK:STDOUT: !39 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !40 = !{!"omnipotent char", !39, i64 0}
|
||||
// CHECK:STDOUT: !41 = !{!"any pointer", !40, i64 0}
|
||||
// CHECK:STDOUT: !42 = !{!"p1 _ZTS8Copyable", !41, i64 0}
|
||||
// CHECK:STDOUT: !43 = !{!42, !42, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !46 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !47 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !48 = !{!"int", !40, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{!"__libc_errno", !48, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{!49, !48, i64 0}
|
||||
// CHECK:STDOUT: !23 = !DILocation(line: 21, column: 21, scope: !21)
|
||||
// CHECK:STDOUT: !24 = !{!22}
|
||||
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "PassValue", linkageName: "_CPassValue.Main", scope: null, file: !6, line: 24, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !31)
|
||||
// CHECK:STDOUT: !26 = !DILocalVariable(arg: 1, scope: !25, type: !8)
|
||||
// CHECK:STDOUT: !29 = !DILocation(line: 25, column: 3, scope: !25)
|
||||
// CHECK:STDOUT: !30 = !DILocation(line: 24, column: 1, scope: !25)
|
||||
// CHECK:STDOUT: !31 = !{!26}
|
||||
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "PassRef", linkageName: "_CPassRef.Main", scope: null, file: !6, line: 28, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !38)
|
||||
// CHECK:STDOUT: !33 = !DILocalVariable(arg: 1, scope: !32, type: !8)
|
||||
// CHECK:STDOUT: !36 = !DILocation(line: 29, column: 3, scope: !32)
|
||||
// CHECK:STDOUT: !37 = !DILocation(line: 28, column: 1, scope: !32)
|
||||
// CHECK:STDOUT: !38 = !{!33}
|
||||
// CHECK:STDOUT: !39 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !6, type: !12, spFlags: DISPFlagDefinition, unit: !7)
|
||||
// CHECK:STDOUT: !40 = !DILocation(line: 14, column: 23, scope: !39)
|
||||
// CHECK:STDOUT: !42 = !DILocation(line: 0, scope: !39)
|
||||
// CHECK:STDOUT: !43 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !44 = !{!"omnipotent char", !43, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{!"any pointer", !44, i64 0}
|
||||
// CHECK:STDOUT: !46 = !{!"p1 _ZTS8Copyable", !45, i64 0}
|
||||
// CHECK:STDOUT: !47 = !{!46, !46, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !50 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !51 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !52 = !{!"int", !44, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!"__libc_errno", !52, i64 0}
|
||||
// CHECK:STDOUT: !54 = !{!53, !52, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'copy_or_move.carbon'
|
||||
@@ -259,17 +273,17 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: define internal void @_Z17make_copy_or_movev.carbon_thunk.(ptr noundef %return) #0 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !81
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !81
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !89
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !89
|
||||
// CHECK:STDOUT: call void @_Z17make_copy_or_movev(ptr dead_on_unwind writable sret(%struct.CopyOrMove) align 1 %0)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassGlobal.Main() #1 !dbg !53 {
|
||||
// CHECK:STDOUT: define void @_CPassGlobal.Main() #1 !dbg !57 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove.carbon_thunk._(ptr @_Cc.Main), !dbg !55
|
||||
// CHECK:STDOUT: ret void, !dbg !56
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove.carbon_thunk._(ptr @_Cc.Main), !dbg !59
|
||||
// CHECK:STDOUT: ret void, !dbg !60
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
@@ -277,8 +291,8 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %agg.tmp = alloca %struct.CopyOrMove, align 1
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !81
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !81
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !89
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !89
|
||||
// CHECK:STDOUT: call void @_ZN10CopyOrMoveC1ERKS_(ptr noundef nonnull align 1 dereferenceable(1) %agg.tmp, ptr noundef nonnull align 1 dereferenceable(1) %1)
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove(ptr nofreeobj noundef align 1 dereferenceable(1) %agg.tmp)
|
||||
// CHECK:STDOUT: call void @_ZN10CopyOrMoveD1Ev(ptr noundef nonnull align 1 dereferenceable(1) %agg.tmp) #1
|
||||
@@ -286,14 +300,14 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassTemporary.Main() #1 !dbg !57 {
|
||||
// CHECK:STDOUT: define void @_CPassTemporary.Main() #1 !dbg !61 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %_.var = alloca [1 x i8], align 1, !dbg !58
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !58
|
||||
// CHECK:STDOUT: call void @_Z17make_copy_or_movev.carbon_thunk.(ptr %_.var), !dbg !59
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove.carbon_thunk.v(ptr %_.var), !dbg !60
|
||||
// CHECK:STDOUT: call void @_ZN10CopyOrMoveD1Ev(ptr %_.var), !dbg !58
|
||||
// CHECK:STDOUT: ret void, !dbg !61
|
||||
// CHECK:STDOUT: %_.var = alloca [1 x i8], align 1, !dbg !62
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !62
|
||||
// CHECK:STDOUT: call void @_Z17make_copy_or_movev.carbon_thunk.(ptr %_.var), !dbg !63
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove.carbon_thunk.v(ptr %_.var), !dbg !64
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.47b8ebd18f50db75:core.Destroy.Core"(ptr %_.var), !dbg !62
|
||||
// CHECK:STDOUT: ret void, !dbg !65
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
@@ -301,8 +315,8 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %agg.tmp = alloca %struct.CopyOrMove, align 1
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !81
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !81
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !89
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !89
|
||||
// CHECK:STDOUT: call void @_ZN10CopyOrMoveC1EOS_(ptr noundef nonnull align 1 dereferenceable(1) %agg.tmp, ptr noundef nonnull align 1 dereferenceable(1) %1)
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove(ptr nofreeobj noundef align 1 dereferenceable(1) %agg.tmp)
|
||||
// CHECK:STDOUT: call void @_ZN10CopyOrMoveD1Ev(ptr noundef nonnull align 1 dereferenceable(1) %agg.tmp) #1
|
||||
@@ -313,27 +327,34 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: declare void @_ZN10CopyOrMoveD1Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassValue.Main(ptr %c) #1 !dbg !62 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.47b8ebd18f50db75:core.Destroy.Core"(ptr %self) #1 !dbg !66 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove.carbon_thunk._(ptr %c), !dbg !66
|
||||
// CHECK:STDOUT: ret void, !dbg !67
|
||||
// CHECK:STDOUT: call void @_ZN10CopyOrMoveD1Ev(ptr %self), !dbg !68
|
||||
// CHECK:STDOUT: ret void, !dbg !68
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassRef.Main(ptr %c) #1 !dbg !69 {
|
||||
// CHECK:STDOUT: define void @_CPassValue.Main(ptr %c) #1 !dbg !70 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove.carbon_thunk._(ptr %c), !dbg !73
|
||||
// CHECK:STDOUT: ret void, !dbg !74
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove.carbon_thunk._(ptr %c), !dbg !74
|
||||
// CHECK:STDOUT: ret void, !dbg !75
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassRef.Main(ptr %c) #1 !dbg !77 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z17pass_copy_or_move10CopyOrMove.carbon_thunk._(ptr %c), !dbg !81
|
||||
// CHECK:STDOUT: ret void, !dbg !82
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define internal void @_C__global_init.Main() #1 !dbg !76 {
|
||||
// CHECK:STDOUT: define internal void @_C__global_init.Main() #1 !dbg !84 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z17make_copy_or_movev.carbon_thunk.(ptr @_Cc.Main), !dbg !77
|
||||
// CHECK:STDOUT: ret void, !dbg !79
|
||||
// CHECK:STDOUT: call void @_Z17make_copy_or_movev.carbon_thunk.(ptr @_Cc.Main), !dbg !85
|
||||
// CHECK:STDOUT: ret void, !dbg !87
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_Z17make_copy_or_movev(ptr dead_on_unwind writable sret(%struct.CopyOrMove) align 1) #4
|
||||
@@ -345,7 +366,7 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: declare void @_ZN10CopyOrMoveC1EOS_(ptr noundef nonnull align 1 dereferenceable(1), ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; uselistorder directives
|
||||
// CHECK:STDOUT: uselistorder ptr @_ZN10CopyOrMoveD1Ev, { 1, 2, 0 }
|
||||
// CHECK:STDOUT: uselistorder ptr @_ZN10CopyOrMoveD1Ev, { 2, 1, 0 }
|
||||
// CHECK:STDOUT: uselistorder ptr @_Z17pass_copy_or_move10CopyOrMove, { 1, 0 }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: attributes #0 = { alwaysinline mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
@@ -354,9 +375,9 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: attributes #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
|
||||
// CHECK:STDOUT: attributes #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!52}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!45, !46, !47, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!50}
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!56}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!49, !50, !51, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!54}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -365,40 +386,44 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: !10 = !DISubroutineType(types: !9)
|
||||
// CHECK:STDOUT: !11 = !{null}
|
||||
// CHECK:STDOUT: !12 = !DISubroutineType(types: !11)
|
||||
// CHECK:STDOUT: !39 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !40 = !{!"omnipotent char", !39, i64 0}
|
||||
// CHECK:STDOUT: !41 = !{!"any pointer", !40, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !46 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !47 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !48 = !{!"int", !40, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{!"__libc_errno", !48, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{!49, !48, i64 0}
|
||||
// CHECK:STDOUT: !51 = !DIFile(filename: "copy_or_move.carbon", directory: "")
|
||||
// CHECK:STDOUT: !52 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !51, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "PassGlobal", linkageName: "_CPassGlobal.Main", scope: null, file: !51, line: 18, type: !12, spFlags: DISPFlagDefinition, unit: !52)
|
||||
// CHECK:STDOUT: !55 = !DILocation(line: 19, column: 3, scope: !53)
|
||||
// CHECK:STDOUT: !56 = !DILocation(line: 18, column: 1, scope: !53)
|
||||
// CHECK:STDOUT: !57 = distinct !DISubprogram(name: "PassTemporary", linkageName: "_CPassTemporary.Main", scope: null, file: !51, line: 22, type: !12, spFlags: DISPFlagDefinition, unit: !52)
|
||||
// CHECK:STDOUT: !58 = !DILocation(line: 13, column: 34, scope: !57)
|
||||
// CHECK:STDOUT: !59 = !DILocation(line: 23, column: 25, scope: !57)
|
||||
// CHECK:STDOUT: !60 = !DILocation(line: 23, column: 3, scope: !57)
|
||||
// CHECK:STDOUT: !61 = !DILocation(line: 22, column: 1, scope: !57)
|
||||
// CHECK:STDOUT: !62 = distinct !DISubprogram(name: "PassValue", linkageName: "_CPassValue.Main", scope: null, file: !51, line: 26, type: !10, spFlags: DISPFlagDefinition, unit: !52, retainedNodes: !68)
|
||||
// CHECK:STDOUT: !63 = !DILocalVariable(arg: 1, scope: !62, type: !8)
|
||||
// CHECK:STDOUT: !66 = !DILocation(line: 27, column: 3, scope: !62)
|
||||
// CHECK:STDOUT: !67 = !DILocation(line: 26, column: 1, scope: !62)
|
||||
// CHECK:STDOUT: !68 = !{!63}
|
||||
// CHECK:STDOUT: !69 = distinct !DISubprogram(name: "PassRef", linkageName: "_CPassRef.Main", scope: null, file: !51, line: 30, type: !10, spFlags: DISPFlagDefinition, unit: !52, retainedNodes: !75)
|
||||
// CHECK:STDOUT: !70 = !DILocalVariable(arg: 1, scope: !69, type: !8)
|
||||
// CHECK:STDOUT: !73 = !DILocation(line: 31, column: 3, scope: !69)
|
||||
// CHECK:STDOUT: !74 = !DILocation(line: 30, column: 1, scope: !69)
|
||||
// CHECK:STDOUT: !75 = !{!70}
|
||||
// CHECK:STDOUT: !76 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !51, type: !12, spFlags: DISPFlagDefinition, unit: !52)
|
||||
// CHECK:STDOUT: !77 = !DILocation(line: 16, column: 25, scope: !76)
|
||||
// CHECK:STDOUT: !79 = !DILocation(line: 0, scope: !76)
|
||||
// CHECK:STDOUT: !80 = !{!"p1 _ZTS10CopyOrMove", !41, i64 0}
|
||||
// CHECK:STDOUT: !81 = !{!80, !80, i64 0}
|
||||
// CHECK:STDOUT: !43 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !44 = !{!"omnipotent char", !43, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{!"any pointer", !44, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !50 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !51 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !52 = !{!"int", !44, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!"__libc_errno", !52, i64 0}
|
||||
// CHECK:STDOUT: !54 = !{!53, !52, i64 0}
|
||||
// CHECK:STDOUT: !55 = !DIFile(filename: "copy_or_move.carbon", directory: "")
|
||||
// CHECK:STDOUT: !56 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !55, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !57 = distinct !DISubprogram(name: "PassGlobal", linkageName: "_CPassGlobal.Main", scope: null, file: !55, line: 18, type: !12, spFlags: DISPFlagDefinition, unit: !56)
|
||||
// CHECK:STDOUT: !59 = !DILocation(line: 19, column: 3, scope: !57)
|
||||
// CHECK:STDOUT: !60 = !DILocation(line: 18, column: 1, scope: !57)
|
||||
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "PassTemporary", linkageName: "_CPassTemporary.Main", scope: null, file: !55, line: 22, type: !12, spFlags: DISPFlagDefinition, unit: !56)
|
||||
// CHECK:STDOUT: !62 = !DILocation(line: 13, column: 34, scope: !61)
|
||||
// CHECK:STDOUT: !63 = !DILocation(line: 23, column: 25, scope: !61)
|
||||
// CHECK:STDOUT: !64 = !DILocation(line: 23, column: 3, scope: !61)
|
||||
// CHECK:STDOUT: !65 = !DILocation(line: 22, column: 1, scope: !61)
|
||||
// CHECK:STDOUT: !66 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.47b8ebd18f50db75:core.Destroy.Core", scope: null, file: !55, line: 13, type: !10, spFlags: DISPFlagDefinition, unit: !56, retainedNodes: !69)
|
||||
// CHECK:STDOUT: !67 = !DILocalVariable(arg: 1, scope: !66, type: !8)
|
||||
// CHECK:STDOUT: !68 = !DILocation(line: 13, column: 34, scope: !66)
|
||||
// CHECK:STDOUT: !69 = !{!67}
|
||||
// CHECK:STDOUT: !70 = distinct !DISubprogram(name: "PassValue", linkageName: "_CPassValue.Main", scope: null, file: !55, line: 26, type: !10, spFlags: DISPFlagDefinition, unit: !56, retainedNodes: !76)
|
||||
// CHECK:STDOUT: !71 = !DILocalVariable(arg: 1, scope: !70, type: !8)
|
||||
// CHECK:STDOUT: !74 = !DILocation(line: 27, column: 3, scope: !70)
|
||||
// CHECK:STDOUT: !75 = !DILocation(line: 26, column: 1, scope: !70)
|
||||
// CHECK:STDOUT: !76 = !{!71}
|
||||
// CHECK:STDOUT: !77 = distinct !DISubprogram(name: "PassRef", linkageName: "_CPassRef.Main", scope: null, file: !55, line: 30, type: !10, spFlags: DISPFlagDefinition, unit: !56, retainedNodes: !83)
|
||||
// CHECK:STDOUT: !78 = !DILocalVariable(arg: 1, scope: !77, type: !8)
|
||||
// CHECK:STDOUT: !81 = !DILocation(line: 31, column: 3, scope: !77)
|
||||
// CHECK:STDOUT: !82 = !DILocation(line: 30, column: 1, scope: !77)
|
||||
// CHECK:STDOUT: !83 = !{!78}
|
||||
// CHECK:STDOUT: !84 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !55, type: !12, spFlags: DISPFlagDefinition, unit: !56)
|
||||
// CHECK:STDOUT: !85 = !DILocation(line: 16, column: 25, scope: !84)
|
||||
// CHECK:STDOUT: !87 = !DILocation(line: 0, scope: !84)
|
||||
// CHECK:STDOUT: !88 = !{!"p1 _ZTS10CopyOrMove", !45, i64 0}
|
||||
// CHECK:STDOUT: !89 = !{!88, !88, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'move_only.carbon'
|
||||
@@ -415,27 +440,27 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: define internal void @_Z14make_move_onlyv.carbon_thunk.(ptr noundef %return) #0 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !97
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !97
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !109
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !109
|
||||
// CHECK:STDOUT: call void @_Z14make_move_onlyv(ptr dead_on_unwind writable sret(%struct.MoveOnly) align 1 %0)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassGlobalByMove.Main() #1 !dbg !85 {
|
||||
// CHECK:STDOUT: define void @_CPassGlobalByMove.Main() #1 !dbg !93 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !86
|
||||
// CHECK:STDOUT: ret void, !dbg !94
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CPassTemporary.Main() #1 !dbg !87 {
|
||||
// CHECK:STDOUT: define void @_CPassTemporary.Main() #1 !dbg !95 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %_.var = alloca [1 x i8], align 1, !dbg !88
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !88
|
||||
// CHECK:STDOUT: call void @_Z14make_move_onlyv.carbon_thunk.(ptr %_.var), !dbg !89
|
||||
// CHECK:STDOUT: call void @_Z14pass_move_only8MoveOnly.carbon_thunk.v(ptr %_.var), !dbg !90
|
||||
// CHECK:STDOUT: call void @_ZN8MoveOnlyD1Ev(ptr %_.var), !dbg !88
|
||||
// CHECK:STDOUT: ret void, !dbg !91
|
||||
// CHECK:STDOUT: %_.var = alloca [1 x i8], align 1, !dbg !96
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !96
|
||||
// CHECK:STDOUT: call void @_Z14make_move_onlyv.carbon_thunk.(ptr %_.var), !dbg !97
|
||||
// CHECK:STDOUT: call void @_Z14pass_move_only8MoveOnly.carbon_thunk.v(ptr %_.var), !dbg !98
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.48e50e337b0b966c:core.Destroy.Core"(ptr %_.var), !dbg !96
|
||||
// CHECK:STDOUT: ret void, !dbg !99
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
@@ -443,8 +468,8 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %agg.tmp = alloca %struct.MoveOnly, align 1
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !97
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !97
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !109
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !109
|
||||
// CHECK:STDOUT: call void @_ZN8MoveOnlyC1EOS_(ptr noundef nonnull align 1 dereferenceable(1) %agg.tmp, ptr noundef nonnull align 1 dereferenceable(1) %1)
|
||||
// CHECK:STDOUT: call void @_Z14pass_move_only8MoveOnly(ptr nofreeobj noundef align 1 dereferenceable(1) %agg.tmp)
|
||||
// CHECK:STDOUT: call void @_ZN8MoveOnlyD1Ev(ptr noundef nonnull align 1 dereferenceable(1) %agg.tmp) #1
|
||||
@@ -454,14 +479,21 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: declare void @_ZN8MoveOnlyD1Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.48e50e337b0b966c:core.Destroy.Core"(ptr %self) #1 !dbg !100 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN8MoveOnlyD1Ev(ptr %self), !dbg !102
|
||||
// CHECK:STDOUT: ret void, !dbg !102
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define internal void @_C__global_init.Main() #1 !dbg !92 {
|
||||
// CHECK:STDOUT: define internal void @_C__global_init.Main() #1 !dbg !104 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Z14make_move_onlyv.carbon_thunk.(ptr @_Cc.Main), !dbg !93
|
||||
// CHECK:STDOUT: ret void, !dbg !95
|
||||
// CHECK:STDOUT: call void @_Z14make_move_onlyv.carbon_thunk.(ptr @_Cc.Main), !dbg !105
|
||||
// CHECK:STDOUT: ret void, !dbg !107
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_Z14make_move_onlyv(ptr dead_on_unwind writable sret(%struct.MoveOnly) align 1) #4
|
||||
@@ -479,35 +511,42 @@ fn PassTemporary() {
|
||||
// CHECK:STDOUT: attributes #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
|
||||
// CHECK:STDOUT: attributes #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!84}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!45, !46, !47, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!50}
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!92}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!49, !50, !51, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!54}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
// CHECK:STDOUT: !8 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
|
||||
// CHECK:STDOUT: !9 = !{null, !8}
|
||||
// CHECK:STDOUT: !10 = !DISubroutineType(types: !9)
|
||||
// CHECK:STDOUT: !11 = !{null}
|
||||
// CHECK:STDOUT: !12 = !DISubroutineType(types: !11)
|
||||
// CHECK:STDOUT: !39 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !40 = !{!"omnipotent char", !39, i64 0}
|
||||
// CHECK:STDOUT: !41 = !{!"any pointer", !40, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !46 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !47 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !48 = !{!"int", !40, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{!"__libc_errno", !48, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{!49, !48, i64 0}
|
||||
// CHECK:STDOUT: !83 = !DIFile(filename: "move_only.carbon", directory: "")
|
||||
// CHECK:STDOUT: !84 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !83, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !85 = distinct !DISubprogram(name: "PassGlobalByMove", linkageName: "_CPassGlobalByMove.Main", scope: null, file: !83, line: 22, type: !12, spFlags: DISPFlagDefinition, unit: !84)
|
||||
// CHECK:STDOUT: !86 = !DILocation(line: 22, column: 1, scope: !85)
|
||||
// CHECK:STDOUT: !87 = distinct !DISubprogram(name: "PassTemporary", linkageName: "_CPassTemporary.Main", scope: null, file: !83, line: 27, type: !12, spFlags: DISPFlagDefinition, unit: !84)
|
||||
// CHECK:STDOUT: !88 = !DILocation(line: 17, column: 29, scope: !87)
|
||||
// CHECK:STDOUT: !89 = !DILocation(line: 28, column: 22, scope: !87)
|
||||
// CHECK:STDOUT: !90 = !DILocation(line: 28, column: 3, scope: !87)
|
||||
// CHECK:STDOUT: !91 = !DILocation(line: 27, column: 1, scope: !87)
|
||||
// CHECK:STDOUT: !92 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !83, type: !12, spFlags: DISPFlagDefinition, unit: !84)
|
||||
// CHECK:STDOUT: !93 = !DILocation(line: 20, column: 23, scope: !92)
|
||||
// CHECK:STDOUT: !95 = !DILocation(line: 0, scope: !92)
|
||||
// CHECK:STDOUT: !96 = !{!"p1 _ZTS8MoveOnly", !41, i64 0}
|
||||
// CHECK:STDOUT: !97 = !{!96, !96, i64 0}
|
||||
// CHECK:STDOUT: !43 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !44 = !{!"omnipotent char", !43, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{!"any pointer", !44, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !50 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !51 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !52 = !{!"int", !44, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!"__libc_errno", !52, i64 0}
|
||||
// CHECK:STDOUT: !54 = !{!53, !52, i64 0}
|
||||
// CHECK:STDOUT: !91 = !DIFile(filename: "move_only.carbon", directory: "")
|
||||
// CHECK:STDOUT: !92 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !91, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !93 = distinct !DISubprogram(name: "PassGlobalByMove", linkageName: "_CPassGlobalByMove.Main", scope: null, file: !91, line: 22, type: !12, spFlags: DISPFlagDefinition, unit: !92)
|
||||
// CHECK:STDOUT: !94 = !DILocation(line: 22, column: 1, scope: !93)
|
||||
// CHECK:STDOUT: !95 = distinct !DISubprogram(name: "PassTemporary", linkageName: "_CPassTemporary.Main", scope: null, file: !91, line: 27, type: !12, spFlags: DISPFlagDefinition, unit: !92)
|
||||
// CHECK:STDOUT: !96 = !DILocation(line: 17, column: 29, scope: !95)
|
||||
// CHECK:STDOUT: !97 = !DILocation(line: 28, column: 22, scope: !95)
|
||||
// CHECK:STDOUT: !98 = !DILocation(line: 28, column: 3, scope: !95)
|
||||
// CHECK:STDOUT: !99 = !DILocation(line: 27, column: 1, scope: !95)
|
||||
// CHECK:STDOUT: !100 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.48e50e337b0b966c:core.Destroy.Core", scope: null, file: !91, line: 17, type: !10, spFlags: DISPFlagDefinition, unit: !92, retainedNodes: !103)
|
||||
// CHECK:STDOUT: !101 = !DILocalVariable(arg: 1, scope: !100, type: !8)
|
||||
// CHECK:STDOUT: !102 = !DILocation(line: 17, column: 29, scope: !100)
|
||||
// CHECK:STDOUT: !103 = !{!101}
|
||||
// CHECK:STDOUT: !104 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !91, type: !12, spFlags: DISPFlagDefinition, unit: !92)
|
||||
// CHECK:STDOUT: !105 = !DILocation(line: 20, column: 23, scope: !104)
|
||||
// CHECK:STDOUT: !107 = !DILocation(line: 0, scope: !104)
|
||||
// CHECK:STDOUT: !108 = !{!"p1 _ZTS8MoveOnly", !45, i64 0}
|
||||
// CHECK:STDOUT: !109 = !{!108, !108, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
+131
-98
@@ -79,8 +79,9 @@ fn DestroyAIndirectly() {
|
||||
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 1 %_.var.loc17, ptr align 1 @Nontrivial.val.loc17_3, i64 0, i1 false), !dbg !44
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var.loc18), !dbg !46
|
||||
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 1 %_.var.loc18, ptr align 1 @Constexpr.val.loc18_3, i64 0, i1 false), !dbg !46
|
||||
// CHECK:STDOUT: call void @_ZN9ConstexprD2Ev(ptr %_.var.loc18), !dbg !46
|
||||
// CHECK:STDOUT: call void @_ZN10NontrivialD1Ev(ptr %_.var.loc17), !dbg !44
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.dec26c21eef1f685:core.Destroy.Core"(ptr %_.var.loc18), !dbg !46
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.c1d87436718894ba:core.Destroy.Core"(ptr %_.var.loc17), !dbg !44
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.74d7ad7746f17264:core.Destroy.Core"(ptr %_.var.loc16), !dbg !42
|
||||
// CHECK:STDOUT: ret void, !dbg !48
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -88,82 +89,102 @@ fn DestroyAIndirectly() {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN9ConstexprD2Ev(ptr noundef nonnull align 1 dereferenceable(1) %this) unnamed_addr #1 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !98
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp:thunk:Destroy.74d6bfd440841f14.Core:Constexpr.Cpp"(ptr %self) #2 !dbg !49 {
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.dec26c21eef1f685:core.Destroy.Core"(ptr %self) #0 !dbg !49 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN9ConstexprD2Ev(ptr %self), !dbg !52
|
||||
// CHECK:STDOUT: ret void, !dbg !52
|
||||
// CHECK:STDOUT: call void @_ZN9ConstexprD2Ev(ptr %self), !dbg !51
|
||||
// CHECK:STDOUT: ret void, !dbg !51
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy:thunk:Destroy.74d6bfd440841f14.Core:Constexpr.Cpp"(ptr %self) #2 !dbg !53 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN9ConstexprD2Ev(ptr %self), !dbg !56
|
||||
// CHECK:STDOUT: ret void, !dbg !56
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: declare void @_ZN10NontrivialD1Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp:thunk:Destroy.470f41253d102356.Core:Trivial.Cpp"(ptr %self) #2 !dbg !54 {
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.c1d87436718894ba:core.Destroy.Core"(ptr %self) #0 !dbg !58 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !57
|
||||
// CHECK:STDOUT: call void @_ZN10NontrivialD1Ev(ptr %self), !dbg !60
|
||||
// CHECK:STDOUT: ret void, !dbg !60
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @"_CMake.Trivial.Cpp:Make.Main"(ptr sret({}) %return) #0 !dbg !59 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.74d7ad7746f17264:core.Destroy.Core"(ptr %self) #0 !dbg !62 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN7TrivialC1Ev.carbon_thunk.(ptr %return), !dbg !62
|
||||
// CHECK:STDOUT: ret void, !dbg !63
|
||||
// CHECK:STDOUT: ret void, !dbg !64
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy:thunk:Destroy.470f41253d102356.Core:Trivial.Cpp"(ptr %self) #2 !dbg !66 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !69
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @"_CMake.Trivial.Cpp:Make.Main"(ptr sret({}) %return) #0 !dbg !71 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN7TrivialC1Ev.carbon_thunk.(ptr %return), !dbg !74
|
||||
// CHECK:STDOUT: ret void, !dbg !75
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
// CHECK:STDOUT: define internal void @_ZN7TrivialC1Ev.carbon_thunk.(ptr noundef %return) #4 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !100
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !100
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !112
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !112
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @"_CMake.Nontrivial.Cpp:Make.Main"(ptr sret({}) %return) #0 !dbg !64 {
|
||||
// CHECK:STDOUT: define void @"_CMake.Nontrivial.Cpp:Make.Main"(ptr sret({}) %return) #0 !dbg !76 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN10NontrivialC1Ev.carbon_thunk.(ptr %return), !dbg !67
|
||||
// CHECK:STDOUT: ret void, !dbg !68
|
||||
// CHECK:STDOUT: call void @_ZN10NontrivialC1Ev.carbon_thunk.(ptr %return), !dbg !79
|
||||
// CHECK:STDOUT: ret void, !dbg !80
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
// CHECK:STDOUT: define internal void @_ZN10NontrivialC1Ev.carbon_thunk.(ptr noundef %return) #4 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !102
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !102
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !114
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !114
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @"_CMake.Constexpr.Cpp:Make.Main"(ptr sret({}) %return) #0 !dbg !69 {
|
||||
// CHECK:STDOUT: define void @"_CMake.Constexpr.Cpp:Make.Main"(ptr sret({}) %return) #0 !dbg !81 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN9ConstexprC1Ev.carbon_thunk.(ptr %return), !dbg !72
|
||||
// CHECK:STDOUT: ret void, !dbg !73
|
||||
// CHECK:STDOUT: call void @_ZN9ConstexprC1Ev.carbon_thunk.(ptr %return), !dbg !84
|
||||
// CHECK:STDOUT: ret void, !dbg !85
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
// CHECK:STDOUT: define internal void @_ZN9ConstexprC1Ev.carbon_thunk.(ptr noundef %return) #4 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !98
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !98
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !110
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CDestroyAIndirectly.Main() #0 !dbg !74 {
|
||||
// CHECK:STDOUT: define void @_CDestroyAIndirectly.Main() #0 !dbg !86 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CDestroyIndirectly.Main.2a28a415478a31f5(), !dbg !75
|
||||
// CHECK:STDOUT: call void @_CDestroyIndirectly.Main.a0f524e76111d8a1(), !dbg !76
|
||||
// CHECK:STDOUT: call void @_CDestroyIndirectly.Main.bf648cc7ac7f04db(), !dbg !77
|
||||
// CHECK:STDOUT: ret void, !dbg !78
|
||||
// CHECK:STDOUT: call void @_CDestroyIndirectly.Main.bbfc87135555afbb(), !dbg !87
|
||||
// CHECK:STDOUT: call void @_CDestroyIndirectly.Main.cbf5e6d817f75fdf(), !dbg !88
|
||||
// CHECK:STDOUT: call void @_CDestroyIndirectly.Main.310c2661ae23419f(), !dbg !89
|
||||
// CHECK:STDOUT: ret void, !dbg !90
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
@@ -173,33 +194,33 @@ fn DestroyAIndirectly() {
|
||||
// CHECK:STDOUT: declare void @llvm.memcpy.p0.p0.i64(ptr noalias writeonly captures(none), ptr noalias readonly captures(none), i64, i1 immarg) #5
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define linkonce_odr void @_CDestroyIndirectly.Main.2a28a415478a31f5() #0 !dbg !79 {
|
||||
// CHECK:STDOUT: define linkonce_odr void @_CDestroyIndirectly.Main.bbfc87135555afbb() #0 !dbg !91 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %a.var = alloca {}, align 1, !dbg !80
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !80
|
||||
// CHECK:STDOUT: call void @"_CMake.Trivial.Cpp:Make.Main"(ptr %a.var), !dbg !81
|
||||
// CHECK:STDOUT: call void @"_COp:thunk:Destroy.470f41253d102356.Core:Trivial.Cpp"(ptr %a.var), !dbg !80
|
||||
// CHECK:STDOUT: ret void, !dbg !83
|
||||
// CHECK:STDOUT: %a.var = alloca {}, align 1, !dbg !92
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !92
|
||||
// CHECK:STDOUT: call void @"_CMake.Trivial.Cpp:Make.Main"(ptr %a.var), !dbg !93
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.74d7ad7746f17264:core.Destroy.Core"(ptr %a.var), !dbg !92
|
||||
// CHECK:STDOUT: ret void, !dbg !95
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define linkonce_odr void @_CDestroyIndirectly.Main.a0f524e76111d8a1() #0 !dbg !84 {
|
||||
// CHECK:STDOUT: define linkonce_odr void @_CDestroyIndirectly.Main.cbf5e6d817f75fdf() #0 !dbg !96 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %a.var = alloca {}, align 1, !dbg !85
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !85
|
||||
// CHECK:STDOUT: call void @"_CMake.Nontrivial.Cpp:Make.Main"(ptr %a.var), !dbg !86
|
||||
// CHECK:STDOUT: call void @_ZN10NontrivialD1Ev(ptr %a.var), !dbg !85
|
||||
// CHECK:STDOUT: ret void, !dbg !88
|
||||
// CHECK:STDOUT: %a.var = alloca {}, align 1, !dbg !97
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !97
|
||||
// CHECK:STDOUT: call void @"_CMake.Nontrivial.Cpp:Make.Main"(ptr %a.var), !dbg !98
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.c1d87436718894ba:core.Destroy.Core"(ptr %a.var), !dbg !97
|
||||
// CHECK:STDOUT: ret void, !dbg !100
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define linkonce_odr void @_CDestroyIndirectly.Main.bf648cc7ac7f04db() #0 !dbg !89 {
|
||||
// CHECK:STDOUT: define linkonce_odr void @_CDestroyIndirectly.Main.310c2661ae23419f() #0 !dbg !101 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %a.var = alloca {}, align 1, !dbg !90
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !90
|
||||
// CHECK:STDOUT: call void @"_CMake.Constexpr.Cpp:Make.Main"(ptr %a.var), !dbg !91
|
||||
// CHECK:STDOUT: call void @"_COp:thunk:Destroy.74d6bfd440841f14.Core:Constexpr.Cpp"(ptr %a.var), !dbg !90
|
||||
// CHECK:STDOUT: ret void, !dbg !93
|
||||
// CHECK:STDOUT: %a.var = alloca {}, align 1, !dbg !102
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !102
|
||||
// CHECK:STDOUT: call void @"_CMake.Constexpr.Cpp:Make.Main"(ptr %a.var), !dbg !103
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.dec26c21eef1f685:core.Destroy.Core"(ptr %a.var), !dbg !102
|
||||
// CHECK:STDOUT: ret void, !dbg !105
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; uselistorder directives
|
||||
@@ -215,8 +236,8 @@ fn DestroyAIndirectly() {
|
||||
// CHECK:STDOUT: attributes #5 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!33}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!103, !104, !105, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!108}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!115, !116, !117, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!120}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -234,53 +255,65 @@ fn DestroyAIndirectly() {
|
||||
// CHECK:STDOUT: !44 = !DILocation(line: 17, column: 3, scope: !41)
|
||||
// CHECK:STDOUT: !46 = !DILocation(line: 18, column: 3, scope: !41)
|
||||
// CHECK:STDOUT: !48 = !DILocation(line: 15, column: 1, scope: !41)
|
||||
// CHECK:STDOUT: !49 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Destroy.74d6bfd440841f14.Core:Constexpr.Cpp", scope: null, file: !32, line: 11, type: !38, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !53)
|
||||
// CHECK:STDOUT: !49 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.dec26c21eef1f685:core.Destroy.Core", scope: null, file: !32, line: 18, type: !38, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !52)
|
||||
// CHECK:STDOUT: !50 = !DILocalVariable(arg: 1, scope: !49, type: !36)
|
||||
// CHECK:STDOUT: !52 = !DILocation(line: 11, column: 13, scope: !49)
|
||||
// CHECK:STDOUT: !53 = !{!50}
|
||||
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Destroy.470f41253d102356.Core:Trivial.Cpp", scope: null, file: !32, line: 6, type: !38, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !58)
|
||||
// CHECK:STDOUT: !55 = !DILocalVariable(arg: 1, scope: !54, type: !36)
|
||||
// CHECK:STDOUT: !57 = !DILocation(line: 6, column: 8, scope: !54)
|
||||
// CHECK:STDOUT: !58 = !{!55}
|
||||
// CHECK:STDOUT: !59 = distinct !DISubprogram(name: "Make", linkageName: "_CMake.Trivial.Cpp:Make.Main", scope: null, file: !32, line: 25, type: !40, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !62 = !DILocation(line: 25, column: 30, scope: !59)
|
||||
// CHECK:STDOUT: !63 = !DILocation(line: 25, column: 23, scope: !59)
|
||||
// CHECK:STDOUT: !64 = distinct !DISubprogram(name: "Make", linkageName: "_CMake.Nontrivial.Cpp:Make.Main", scope: null, file: !32, line: 28, type: !40, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !67 = !DILocation(line: 28, column: 30, scope: !64)
|
||||
// CHECK:STDOUT: !68 = !DILocation(line: 28, column: 23, scope: !64)
|
||||
// CHECK:STDOUT: !69 = distinct !DISubprogram(name: "Make", linkageName: "_CMake.Constexpr.Cpp:Make.Main", scope: null, file: !32, line: 31, type: !40, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !72 = !DILocation(line: 31, column: 30, scope: !69)
|
||||
// CHECK:STDOUT: !73 = !DILocation(line: 31, column: 23, scope: !69)
|
||||
// CHECK:STDOUT: !74 = distinct !DISubprogram(name: "DestroyAIndirectly", linkageName: "_CDestroyAIndirectly.Main", scope: null, file: !32, line: 38, type: !35, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !75 = !DILocation(line: 39, column: 3, scope: !74)
|
||||
// CHECK:STDOUT: !76 = !DILocation(line: 40, column: 3, scope: !74)
|
||||
// CHECK:STDOUT: !77 = !DILocation(line: 41, column: 3, scope: !74)
|
||||
// CHECK:STDOUT: !78 = !DILocation(line: 38, column: 1, scope: !74)
|
||||
// CHECK:STDOUT: !79 = distinct !DISubprogram(name: "DestroyIndirectly", linkageName: "_CDestroyIndirectly.Main.2a28a415478a31f5", scope: null, file: !32, line: 34, type: !35, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !80 = !DILocation(line: 35, column: 3, scope: !79)
|
||||
// CHECK:STDOUT: !81 = !DILocation(line: 35, column: 21, scope: !79)
|
||||
// CHECK:STDOUT: !83 = !DILocation(line: 34, column: 1, scope: !79)
|
||||
// CHECK:STDOUT: !84 = distinct !DISubprogram(name: "DestroyIndirectly", linkageName: "_CDestroyIndirectly.Main.a0f524e76111d8a1", scope: null, file: !32, line: 34, type: !35, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !85 = !DILocation(line: 35, column: 3, scope: !84)
|
||||
// CHECK:STDOUT: !86 = !DILocation(line: 35, column: 21, scope: !84)
|
||||
// CHECK:STDOUT: !88 = !DILocation(line: 34, column: 1, scope: !84)
|
||||
// CHECK:STDOUT: !89 = distinct !DISubprogram(name: "DestroyIndirectly", linkageName: "_CDestroyIndirectly.Main.bf648cc7ac7f04db", scope: null, file: !32, line: 34, type: !35, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !90 = !DILocation(line: 35, column: 3, scope: !89)
|
||||
// CHECK:STDOUT: !91 = !DILocation(line: 35, column: 21, scope: !89)
|
||||
// CHECK:STDOUT: !93 = !DILocation(line: 34, column: 1, scope: !89)
|
||||
// CHECK:STDOUT: !94 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !95 = !{!"omnipotent char", !94, i64 0}
|
||||
// CHECK:STDOUT: !96 = !{!"any pointer", !95, i64 0}
|
||||
// CHECK:STDOUT: !97 = !{!"p1 _ZTS9Constexpr", !96, i64 0}
|
||||
// CHECK:STDOUT: !98 = !{!97, !97, i64 0}
|
||||
// CHECK:STDOUT: !99 = !{!"p1 _ZTS7Trivial", !96, i64 0}
|
||||
// CHECK:STDOUT: !100 = !{!99, !99, i64 0}
|
||||
// CHECK:STDOUT: !101 = !{!"p1 _ZTS10Nontrivial", !96, i64 0}
|
||||
// CHECK:STDOUT: !102 = !{!101, !101, i64 0}
|
||||
// CHECK:STDOUT: !103 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !104 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !105 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !106 = !{!"int", !95, i64 0}
|
||||
// CHECK:STDOUT: !107 = !{!"__libc_errno", !106, i64 0}
|
||||
// CHECK:STDOUT: !108 = !{!107, !106, i64 0}
|
||||
// CHECK:STDOUT: !51 = !DILocation(line: 18, column: 3, scope: !49)
|
||||
// CHECK:STDOUT: !52 = !{!50}
|
||||
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy:thunk:Destroy.74d6bfd440841f14.Core:Constexpr.Cpp", scope: null, file: !32, line: 11, type: !38, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !57)
|
||||
// CHECK:STDOUT: !54 = !DILocalVariable(arg: 1, scope: !53, type: !36)
|
||||
// CHECK:STDOUT: !56 = !DILocation(line: 11, column: 13, scope: !53)
|
||||
// CHECK:STDOUT: !57 = !{!54}
|
||||
// CHECK:STDOUT: !58 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.c1d87436718894ba:core.Destroy.Core", scope: null, file: !32, line: 17, type: !38, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !61)
|
||||
// CHECK:STDOUT: !59 = !DILocalVariable(arg: 1, scope: !58, type: !36)
|
||||
// CHECK:STDOUT: !60 = !DILocation(line: 17, column: 3, scope: !58)
|
||||
// CHECK:STDOUT: !61 = !{!59}
|
||||
// CHECK:STDOUT: !62 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.74d7ad7746f17264:core.Destroy.Core", scope: null, file: !32, line: 16, type: !38, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !65)
|
||||
// CHECK:STDOUT: !63 = !DILocalVariable(arg: 1, scope: !62, type: !36)
|
||||
// CHECK:STDOUT: !64 = !DILocation(line: 16, column: 3, scope: !62)
|
||||
// CHECK:STDOUT: !65 = !{!63}
|
||||
// CHECK:STDOUT: !66 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy:thunk:Destroy.470f41253d102356.Core:Trivial.Cpp", scope: null, file: !32, line: 6, type: !38, spFlags: DISPFlagDefinition, unit: !33, retainedNodes: !70)
|
||||
// CHECK:STDOUT: !67 = !DILocalVariable(arg: 1, scope: !66, type: !36)
|
||||
// CHECK:STDOUT: !69 = !DILocation(line: 6, column: 8, scope: !66)
|
||||
// CHECK:STDOUT: !70 = !{!67}
|
||||
// CHECK:STDOUT: !71 = distinct !DISubprogram(name: "Make", linkageName: "_CMake.Trivial.Cpp:Make.Main", scope: null, file: !32, line: 25, type: !40, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !74 = !DILocation(line: 25, column: 30, scope: !71)
|
||||
// CHECK:STDOUT: !75 = !DILocation(line: 25, column: 23, scope: !71)
|
||||
// CHECK:STDOUT: !76 = distinct !DISubprogram(name: "Make", linkageName: "_CMake.Nontrivial.Cpp:Make.Main", scope: null, file: !32, line: 28, type: !40, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !79 = !DILocation(line: 28, column: 30, scope: !76)
|
||||
// CHECK:STDOUT: !80 = !DILocation(line: 28, column: 23, scope: !76)
|
||||
// CHECK:STDOUT: !81 = distinct !DISubprogram(name: "Make", linkageName: "_CMake.Constexpr.Cpp:Make.Main", scope: null, file: !32, line: 31, type: !40, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !84 = !DILocation(line: 31, column: 30, scope: !81)
|
||||
// CHECK:STDOUT: !85 = !DILocation(line: 31, column: 23, scope: !81)
|
||||
// CHECK:STDOUT: !86 = distinct !DISubprogram(name: "DestroyAIndirectly", linkageName: "_CDestroyAIndirectly.Main", scope: null, file: !32, line: 38, type: !35, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !87 = !DILocation(line: 39, column: 3, scope: !86)
|
||||
// CHECK:STDOUT: !88 = !DILocation(line: 40, column: 3, scope: !86)
|
||||
// CHECK:STDOUT: !89 = !DILocation(line: 41, column: 3, scope: !86)
|
||||
// CHECK:STDOUT: !90 = !DILocation(line: 38, column: 1, scope: !86)
|
||||
// CHECK:STDOUT: !91 = distinct !DISubprogram(name: "DestroyIndirectly", linkageName: "_CDestroyIndirectly.Main.bbfc87135555afbb", scope: null, file: !32, line: 34, type: !35, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !92 = !DILocation(line: 35, column: 3, scope: !91)
|
||||
// CHECK:STDOUT: !93 = !DILocation(line: 35, column: 21, scope: !91)
|
||||
// CHECK:STDOUT: !95 = !DILocation(line: 34, column: 1, scope: !91)
|
||||
// CHECK:STDOUT: !96 = distinct !DISubprogram(name: "DestroyIndirectly", linkageName: "_CDestroyIndirectly.Main.cbf5e6d817f75fdf", scope: null, file: !32, line: 34, type: !35, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !97 = !DILocation(line: 35, column: 3, scope: !96)
|
||||
// CHECK:STDOUT: !98 = !DILocation(line: 35, column: 21, scope: !96)
|
||||
// CHECK:STDOUT: !100 = !DILocation(line: 34, column: 1, scope: !96)
|
||||
// CHECK:STDOUT: !101 = distinct !DISubprogram(name: "DestroyIndirectly", linkageName: "_CDestroyIndirectly.Main.310c2661ae23419f", scope: null, file: !32, line: 34, type: !35, spFlags: DISPFlagDefinition, unit: !33)
|
||||
// CHECK:STDOUT: !102 = !DILocation(line: 35, column: 3, scope: !101)
|
||||
// CHECK:STDOUT: !103 = !DILocation(line: 35, column: 21, scope: !101)
|
||||
// CHECK:STDOUT: !105 = !DILocation(line: 34, column: 1, scope: !101)
|
||||
// CHECK:STDOUT: !106 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !107 = !{!"omnipotent char", !106, i64 0}
|
||||
// CHECK:STDOUT: !108 = !{!"any pointer", !107, i64 0}
|
||||
// CHECK:STDOUT: !109 = !{!"p1 _ZTS9Constexpr", !108, i64 0}
|
||||
// CHECK:STDOUT: !110 = !{!109, !109, i64 0}
|
||||
// CHECK:STDOUT: !111 = !{!"p1 _ZTS7Trivial", !108, i64 0}
|
||||
// CHECK:STDOUT: !112 = !{!111, !111, i64 0}
|
||||
// CHECK:STDOUT: !113 = !{!"p1 _ZTS10Nontrivial", !108, i64 0}
|
||||
// CHECK:STDOUT: !114 = !{!113, !113, i64 0}
|
||||
// CHECK:STDOUT: !115 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !116 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !117 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !118 = !{!"int", !107, i64 0}
|
||||
// CHECK:STDOUT: !119 = !{!"__libc_errno", !118, i64 0}
|
||||
// CHECK:STDOUT: !120 = !{!119, !118, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -104,53 +104,73 @@ fn DoThing() {
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.Derived.Main"(ptr %self) #3 !dbg !60 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.b25525d21a9bd472:core.Destroy.Core"(ptr %self), !dbg !62
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.b25525d21a9bd472:core.Destroy.Core"(ptr %self), !dbg !62
|
||||
// CHECK:STDOUT: ret void, !dbg !62
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.0a0b9df20a60c6f6:core.Destroy.Core"(ptr %self) #2 !dbg !64 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.352b8f386f44a614:core.Destroy.Core"(ptr %self) #2 !dbg !64 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !66
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.b25525d21a9bd472:core.Destroy.Core"(ptr %self) #2 !dbg !68 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.0a0b9df20a60c6f6:core.Destroy.Core"(ptr %self) #2 !dbg !68 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !70
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_Cfunc__carbon_thunk.Derived.Main(ptr %self) #2 !dbg !72 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.0a0b9df20a60c6f6:core.Destroy.Core"(ptr %self) #2 !dbg !72 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Cfunc.Derived.Main(ptr %self), !dbg !74
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.0a0b9df20a60c6f6:core.Destroy.Core"(ptr %self), !dbg !74
|
||||
// CHECK:STDOUT: ret void, !dbg !74
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_Cother_func__carbon_thunk.Derived.Main(ptr %self) #2 !dbg !76 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.b25525d21a9bd472:core.Destroy.Core"(ptr %self) #2 !dbg !76 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %Derived.other_func.call.vtable = load ptr, ptr %self, align 8, !dbg !78
|
||||
// CHECK:STDOUT: %Derived.other_func.call = call ptr @llvm.load.relative.i32(ptr %Derived.other_func.call.vtable, i32 8), !dbg !78
|
||||
// CHECK:STDOUT: call void %Derived.other_func.call(ptr %self), !dbg !78
|
||||
// CHECK:STDOUT: ret void, !dbg !78
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CDoThing.Main() #2 !dbg !80 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.b25525d21a9bd472:core.Destroy.Core"(ptr %self) #2 !dbg !80 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %d.var = alloca { [16 x i8] }, align 8, !dbg !81
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %d.var), !dbg !81
|
||||
// CHECK:STDOUT: %.loc31_44.1.base = getelementptr inbounds nuw { [16 x i8] }, ptr %d.var, i32 0, i32 0, !dbg !82
|
||||
// CHECK:STDOUT: call void @_ZN4BaseC1Ev.carbon_thunk.(ptr %.loc31_44.1.base), !dbg !83
|
||||
// CHECK:STDOUT: %.loc31_44.7.base = getelementptr inbounds nuw { [16 x i8] }, ptr %d.var, i32 0, i32 0, !dbg !82
|
||||
// CHECK:STDOUT: %.loc31_44.8.base = getelementptr inbounds nuw [16 x i8], ptr %.loc31_44.7.base, i32 0, i32 0, !dbg !82
|
||||
// CHECK:STDOUT: %.loc31_44.9.vptr = getelementptr inbounds nuw [8 x i8], ptr %.loc31_44.8.base, i32 0, i32 0, !dbg !82
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 24) ({ [5 x ptr] }, ptr @_ZTVN6Carbon7DerivedE, i32 0, i32 0, i32 2), ptr %.loc31_44.9.vptr, align 8, !dbg !82
|
||||
// CHECK:STDOUT: %.loc32_11.2.base = getelementptr inbounds nuw { [16 x i8] }, ptr %d.var, i32 0, i32 0, !dbg !86
|
||||
// CHECK:STDOUT: call void @_Z3UseR4Base(ptr %.loc32_11.2.base), !dbg !87
|
||||
// CHECK:STDOUT: call void @"_COp.b25525d21a9bd472:core.Destroy.Core"(ptr %d.var), !dbg !81
|
||||
// CHECK:STDOUT: ret void, !dbg !88
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.b25525d21a9bd472:core.Destroy.Core"(ptr %self), !dbg !82
|
||||
// CHECK:STDOUT: ret void, !dbg !82
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_Cfunc__carbon_thunk.Derived.Main(ptr %self) #2 !dbg !84 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Cfunc.Derived.Main(ptr %self), !dbg !86
|
||||
// CHECK:STDOUT: ret void, !dbg !86
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_Cother_func__carbon_thunk.Derived.Main(ptr %self) #2 !dbg !88 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %Derived.other_func.call.vtable = load ptr, ptr %self, align 8, !dbg !90
|
||||
// CHECK:STDOUT: %Derived.other_func.call = call ptr @llvm.load.relative.i32(ptr %Derived.other_func.call.vtable, i32 8), !dbg !90
|
||||
// CHECK:STDOUT: call void %Derived.other_func.call(ptr %self), !dbg !90
|
||||
// CHECK:STDOUT: ret void, !dbg !90
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CDoThing.Main() #2 !dbg !92 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %d.var = alloca { [16 x i8] }, align 8, !dbg !93
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %d.var), !dbg !93
|
||||
// CHECK:STDOUT: %.loc31_44.1.base = getelementptr inbounds nuw { [16 x i8] }, ptr %d.var, i32 0, i32 0, !dbg !94
|
||||
// CHECK:STDOUT: call void @_ZN4BaseC1Ev.carbon_thunk.(ptr %.loc31_44.1.base), !dbg !95
|
||||
// CHECK:STDOUT: %.loc31_44.7.base = getelementptr inbounds nuw { [16 x i8] }, ptr %d.var, i32 0, i32 0, !dbg !94
|
||||
// CHECK:STDOUT: %.loc31_44.8.base = getelementptr inbounds nuw [16 x i8], ptr %.loc31_44.7.base, i32 0, i32 0, !dbg !94
|
||||
// CHECK:STDOUT: %.loc31_44.9.vptr = getelementptr inbounds nuw [8 x i8], ptr %.loc31_44.8.base, i32 0, i32 0, !dbg !94
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 24) ({ [5 x ptr] }, ptr @_ZTVN6Carbon7DerivedE, i32 0, i32 0, i32 2), ptr %.loc31_44.9.vptr, align 8, !dbg !94
|
||||
// CHECK:STDOUT: %.loc32_11.2.base = getelementptr inbounds nuw { [16 x i8] }, ptr %d.var, i32 0, i32 0, !dbg !98
|
||||
// CHECK:STDOUT: call void @_Z3UseR4Base(ptr %.loc32_11.2.base), !dbg !99
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.b25525d21a9bd472:core.Destroy.Core"(ptr %d.var), !dbg !93
|
||||
// CHECK:STDOUT: ret void, !dbg !100
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
@@ -173,7 +193,7 @@ fn DoThing() {
|
||||
// CHECK:STDOUT: define internal void @_ZNR6Carbon7Derived4funcEv(ptr noundef nonnull align 8 dereferenceable(12) %this) unnamed_addr #4 align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !94
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !106
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @_Cfunc__carbon_thunk.Derived.Main(ptr noundef nonnull align 8 dereferenceable(12) %this1)
|
||||
// CHECK:STDOUT: ret void
|
||||
@@ -183,7 +203,7 @@ fn DoThing() {
|
||||
// CHECK:STDOUT: define internal void @_ZNK6Carbon7Derived10other_funcEv(ptr noundef nonnull align 8 dereferenceable(12) %this) unnamed_addr #4 align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !94
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !106
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @_Cother_func__carbon_thunk.Derived.Main(ptr noundef nonnull align 8 dereferenceable(12) %this1)
|
||||
// CHECK:STDOUT: ret void
|
||||
@@ -196,7 +216,7 @@ fn DoThing() {
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !4
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @_ZN11FurtherBaseC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %this1) #2
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 16) ({ [4 x ptr] }, ptr @_ZTV4Base, i32 0, i32 0, i32 2), ptr %this1, align 8, !tbaa !90
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 16) ({ [4 x ptr] }, ptr @_ZTV4Base, i32 0, i32 0, i32 2), ptr %this1, align 8, !tbaa !102
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -204,9 +224,9 @@ fn DoThing() {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN11FurtherBaseC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %this) unnamed_addr #7 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !92
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !104
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 8) ({ [3 x ptr] }, ptr @_ZTV11FurtherBase, i32 0, i32 0, i32 2), ptr %this1, align 8, !tbaa !90
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 8) ({ [3 x ptr] }, ptr @_ZTV11FurtherBase, i32 0, i32 0, i32 2), ptr %this1, align 8, !tbaa !102
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -223,8 +243,8 @@ fn DoThing() {
|
||||
// CHECK:STDOUT: attributes #7 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!38}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!99, !100, !101, !7, !8}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!103}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!111, !112, !113, !7, !8}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!115}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !0 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !1 = !{!"omnipotent char", !0, i64 0}
|
||||
@@ -256,39 +276,51 @@ fn DoThing() {
|
||||
// CHECK:STDOUT: !61 = !DILocalVariable(arg: 1, scope: !60, type: !40)
|
||||
// CHECK:STDOUT: !62 = !DILocation(line: 22, column: 1, scope: !60)
|
||||
// CHECK:STDOUT: !63 = !{!61}
|
||||
// CHECK:STDOUT: !64 = distinct !DISubprogram(name: "Op", linkageName: "_COp.0a0b9df20a60c6f6:core.Destroy.Core", scope: null, file: !37, line: 22, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !67)
|
||||
// CHECK:STDOUT: !64 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.352b8f386f44a614:core.Destroy.Core", scope: null, file: !37, line: 22, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !67)
|
||||
// CHECK:STDOUT: !65 = !DILocalVariable(arg: 1, scope: !64, type: !40)
|
||||
// CHECK:STDOUT: !66 = !DILocation(line: 22, column: 1, scope: !64)
|
||||
// CHECK:STDOUT: !67 = !{!65}
|
||||
// CHECK:STDOUT: !68 = distinct !DISubprogram(name: "Op", linkageName: "_COp.b25525d21a9bd472:core.Destroy.Core", scope: null, file: !37, line: 22, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !71)
|
||||
// CHECK:STDOUT: !68 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.0a0b9df20a60c6f6:core.Destroy.Core", scope: null, file: !37, line: 22, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !71)
|
||||
// CHECK:STDOUT: !69 = !DILocalVariable(arg: 1, scope: !68, type: !40)
|
||||
// CHECK:STDOUT: !70 = !DILocation(line: 22, column: 1, scope: !68)
|
||||
// CHECK:STDOUT: !71 = !{!69}
|
||||
// CHECK:STDOUT: !72 = distinct !DISubprogram(name: "func__carbon_thunk", linkageName: "_Cfunc__carbon_thunk.Derived.Main", scope: null, file: !37, line: 26, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !75)
|
||||
// CHECK:STDOUT: !72 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.0a0b9df20a60c6f6:core.Destroy.Core", scope: null, file: !37, line: 22, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !75)
|
||||
// CHECK:STDOUT: !73 = !DILocalVariable(arg: 1, scope: !72, type: !40)
|
||||
// CHECK:STDOUT: !74 = !DILocation(line: 26, column: 3, scope: !72)
|
||||
// CHECK:STDOUT: !74 = !DILocation(line: 22, column: 1, scope: !72)
|
||||
// CHECK:STDOUT: !75 = !{!73}
|
||||
// CHECK:STDOUT: !76 = distinct !DISubprogram(name: "other_func__carbon_thunk", linkageName: "_Cother_func__carbon_thunk.Derived.Main", scope: null, file: !37, line: 24, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !79)
|
||||
// CHECK:STDOUT: !76 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.b25525d21a9bd472:core.Destroy.Core", scope: null, file: !37, line: 22, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !79)
|
||||
// CHECK:STDOUT: !77 = !DILocalVariable(arg: 1, scope: !76, type: !40)
|
||||
// CHECK:STDOUT: !78 = !DILocation(line: 24, column: 3, scope: !76)
|
||||
// CHECK:STDOUT: !78 = !DILocation(line: 22, column: 1, scope: !76)
|
||||
// CHECK:STDOUT: !79 = !{!77}
|
||||
// CHECK:STDOUT: !80 = distinct !DISubprogram(name: "DoThing", linkageName: "_CDoThing.Main", scope: null, file: !37, line: 30, type: !44, spFlags: DISPFlagDefinition, unit: !38)
|
||||
// CHECK:STDOUT: !81 = !DILocation(line: 31, column: 3, scope: !80)
|
||||
// CHECK:STDOUT: !82 = !DILocation(line: 31, column: 20, scope: !80)
|
||||
// CHECK:STDOUT: !83 = !DILocation(line: 31, column: 29, scope: !80)
|
||||
// CHECK:STDOUT: !86 = !DILocation(line: 32, column: 11, scope: !80)
|
||||
// CHECK:STDOUT: !87 = !DILocation(line: 32, column: 3, scope: !80)
|
||||
// CHECK:STDOUT: !88 = !DILocation(line: 30, column: 1, scope: !80)
|
||||
// CHECK:STDOUT: !89 = !{!"vtable pointer", !0, i64 0}
|
||||
// CHECK:STDOUT: !90 = !{!89, !89, i64 0}
|
||||
// CHECK:STDOUT: !91 = !{!"p1 _ZTS11FurtherBase", !2, i64 0}
|
||||
// CHECK:STDOUT: !92 = !{!91, !91, i64 0}
|
||||
// CHECK:STDOUT: !93 = !{!"p1 _ZTSN6Carbon7DerivedE", !2, i64 0}
|
||||
// CHECK:STDOUT: !94 = !{!93, !93, i64 0}
|
||||
// CHECK:STDOUT: !96 = !{!"int", !1, i64 0}
|
||||
// CHECK:STDOUT: !99 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !100 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !101 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !102 = !{!"__libc_errno", !96, i64 0}
|
||||
// CHECK:STDOUT: !103 = !{!102, !96, i64 0}
|
||||
// CHECK:STDOUT: !80 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.b25525d21a9bd472:core.Destroy.Core", scope: null, file: !37, line: 22, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !83)
|
||||
// CHECK:STDOUT: !81 = !DILocalVariable(arg: 1, scope: !80, type: !40)
|
||||
// CHECK:STDOUT: !82 = !DILocation(line: 22, column: 1, scope: !80)
|
||||
// CHECK:STDOUT: !83 = !{!81}
|
||||
// CHECK:STDOUT: !84 = distinct !DISubprogram(name: "func__carbon_thunk", linkageName: "_Cfunc__carbon_thunk.Derived.Main", scope: null, file: !37, line: 26, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !87)
|
||||
// CHECK:STDOUT: !85 = !DILocalVariable(arg: 1, scope: !84, type: !40)
|
||||
// CHECK:STDOUT: !86 = !DILocation(line: 26, column: 3, scope: !84)
|
||||
// CHECK:STDOUT: !87 = !{!85}
|
||||
// CHECK:STDOUT: !88 = distinct !DISubprogram(name: "other_func__carbon_thunk", linkageName: "_Cother_func__carbon_thunk.Derived.Main", scope: null, file: !37, line: 24, type: !42, spFlags: DISPFlagDefinition, unit: !38, retainedNodes: !91)
|
||||
// CHECK:STDOUT: !89 = !DILocalVariable(arg: 1, scope: !88, type: !40)
|
||||
// CHECK:STDOUT: !90 = !DILocation(line: 24, column: 3, scope: !88)
|
||||
// CHECK:STDOUT: !91 = !{!89}
|
||||
// CHECK:STDOUT: !92 = distinct !DISubprogram(name: "DoThing", linkageName: "_CDoThing.Main", scope: null, file: !37, line: 30, type: !44, spFlags: DISPFlagDefinition, unit: !38)
|
||||
// CHECK:STDOUT: !93 = !DILocation(line: 31, column: 3, scope: !92)
|
||||
// CHECK:STDOUT: !94 = !DILocation(line: 31, column: 20, scope: !92)
|
||||
// CHECK:STDOUT: !95 = !DILocation(line: 31, column: 29, scope: !92)
|
||||
// CHECK:STDOUT: !98 = !DILocation(line: 32, column: 11, scope: !92)
|
||||
// CHECK:STDOUT: !99 = !DILocation(line: 32, column: 3, scope: !92)
|
||||
// CHECK:STDOUT: !100 = !DILocation(line: 30, column: 1, scope: !92)
|
||||
// CHECK:STDOUT: !101 = !{!"vtable pointer", !0, i64 0}
|
||||
// CHECK:STDOUT: !102 = !{!101, !101, i64 0}
|
||||
// CHECK:STDOUT: !103 = !{!"p1 _ZTS11FurtherBase", !2, i64 0}
|
||||
// CHECK:STDOUT: !104 = !{!103, !103, i64 0}
|
||||
// CHECK:STDOUT: !105 = !{!"p1 _ZTSN6Carbon7DerivedE", !2, i64 0}
|
||||
// CHECK:STDOUT: !106 = !{!105, !105, i64 0}
|
||||
// CHECK:STDOUT: !108 = !{!"int", !1, i64 0}
|
||||
// CHECK:STDOUT: !111 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !112 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !113 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !114 = !{!"__libc_errno", !108, i64 0}
|
||||
// CHECK:STDOUT: !115 = !{!114, !108, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
+52
-31
@@ -334,10 +334,10 @@ fn F(ref r: Cpp.RefSelfA) {
|
||||
// CHECK:STDOUT: %.loc8_14.3.temp = alloca i8, align 1, !dbg !82
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_14.3.temp), !dbg !80
|
||||
// CHECK:STDOUT: call void @_ZNK9NeedThunk8ImplicitEa.carbon_thunk.__(ptr %n, ptr @int_1.f1e), !dbg !79
|
||||
// CHECK:STDOUT: call void @"_COp.4954785a8b134801:core.Destroy.Core"(ptr @int_1.f1e), !dbg !80
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.4954785a8b134801:core.Destroy.Core"(ptr @int_1.f1e), !dbg !80
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc8_14.3.temp), !dbg !82
|
||||
// CHECK:STDOUT: call void @_ZNH9NeedThunk8ExplicitES_a.carbon_thunk.__(ptr %n, ptr @int_1.f1e), !dbg !81
|
||||
// CHECK:STDOUT: call void @"_COp.4954785a8b134801:core.Destroy.Core"(ptr @int_1.f1e), !dbg !82
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.4954785a8b134801:core.Destroy.Core"(ptr @int_1.f1e), !dbg !82
|
||||
// CHECK:STDOUT: ret void, !dbg !83
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -346,32 +346,45 @@ fn F(ref r: Cpp.RefSelfA) {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %c.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !90
|
||||
// CHECK:STDOUT: store ptr %c, ptr %c.addr, align 8, !tbaa !92
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %this.addr, align 8, !tbaa !90, !nonnull !42
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %c.addr, align 8, !tbaa !92
|
||||
// CHECK:STDOUT: %2 = load i8, ptr %1, align 1, !tbaa !94
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !98
|
||||
// CHECK:STDOUT: store ptr %c, ptr %c.addr, align 8, !tbaa !100
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %this.addr, align 8, !tbaa !98, !nonnull !42
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %c.addr, align 8, !tbaa !100
|
||||
// CHECK:STDOUT: %2 = load i8, ptr %1, align 1, !tbaa !102
|
||||
// CHECK:STDOUT: call void @_ZNK9NeedThunk8ImplicitEa(ptr noundef nonnull align 1 dereferenceable(1) %0, i8 noundef signext %2)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.4954785a8b134801:core.Destroy.Core"(ptr %self) #0 !dbg !85 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.c4a4fcc00062c7f0:core.Destroy.Core"(ptr %self) #0 !dbg !85 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !87
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.4954785a8b134801:core.Destroy.Core"(ptr %self) #0 !dbg !89 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !91
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.4954785a8b134801:core.Destroy.Core"(ptr %self) #0 !dbg !93 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.4954785a8b134801:core.Destroy.Core"(ptr %self), !dbg !95
|
||||
// CHECK:STDOUT: ret void, !dbg !95
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
|
||||
// CHECK:STDOUT: define internal void @_ZNH9NeedThunk8ExplicitES_a.carbon_thunk.__(ptr noundef %0, ptr noundef %c) #1 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %c.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: %agg.tmp = alloca %struct.NeedThunk, align 1
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !90
|
||||
// CHECK:STDOUT: store ptr %c, ptr %c.addr, align 8, !tbaa !92
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !90
|
||||
// CHECK:STDOUT: %2 = load ptr, ptr %c.addr, align 8, !tbaa !92
|
||||
// CHECK:STDOUT: %3 = load i8, ptr %2, align 1, !tbaa !94
|
||||
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !98
|
||||
// CHECK:STDOUT: store ptr %c, ptr %c.addr, align 8, !tbaa !100
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !98
|
||||
// CHECK:STDOUT: %2 = load ptr, ptr %c.addr, align 8, !tbaa !100
|
||||
// CHECK:STDOUT: %3 = load i8, ptr %2, align 1, !tbaa !102
|
||||
// CHECK:STDOUT: call void @_ZNH9NeedThunk8ExplicitES_a(i8 noundef signext %3)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
@@ -384,7 +397,7 @@ fn F(ref r: Cpp.RefSelfA) {
|
||||
// CHECK:STDOUT: declare void @_ZNH9NeedThunk8ExplicitES_a(i8 noundef signext) #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; uselistorder directives
|
||||
// CHECK:STDOUT: uselistorder ptr @"_COp.4954785a8b134801:core.Destroy.Core", { 1, 0 }
|
||||
// CHECK:STDOUT: uselistorder ptr @"_CSelfDestruct.4954785a8b134801:core.Destroy.Core", { 1, 0 }
|
||||
// CHECK:STDOUT: uselistorder ptr @llvm.lifetime.start.p0, { 1, 0 }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: attributes #0 = { nounwind }
|
||||
@@ -424,15 +437,23 @@ fn F(ref r: Cpp.RefSelfA) {
|
||||
// CHECK:STDOUT: !82 = !DILocation(line: 8, column: 14, scope: !76)
|
||||
// CHECK:STDOUT: !83 = !DILocation(line: 6, column: 1, scope: !76)
|
||||
// CHECK:STDOUT: !84 = !{!77}
|
||||
// CHECK:STDOUT: !85 = distinct !DISubprogram(name: "Op", linkageName: "_COp.4954785a8b134801:core.Destroy.Core", scope: null, file: !69, line: 7, type: !75, spFlags: DISPFlagDefinition, unit: !70, retainedNodes: !88)
|
||||
// CHECK:STDOUT: !85 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.c4a4fcc00062c7f0:core.Destroy.Core", scope: null, file: !69, line: 7, type: !75, spFlags: DISPFlagDefinition, unit: !70, retainedNodes: !88)
|
||||
// CHECK:STDOUT: !86 = !DILocalVariable(arg: 1, scope: !85, type: !71)
|
||||
// CHECK:STDOUT: !87 = !DILocation(line: 7, column: 14, scope: !85)
|
||||
// CHECK:STDOUT: !88 = !{!86}
|
||||
// CHECK:STDOUT: !89 = !{!"p1 _ZTS9NeedThunk", !36, i64 0}
|
||||
// CHECK:STDOUT: !90 = !{!89, !89, i64 0}
|
||||
// CHECK:STDOUT: !91 = !{!"p1 omnipotent char", !36, i64 0}
|
||||
// CHECK:STDOUT: !92 = !{!91, !91, i64 0}
|
||||
// CHECK:STDOUT: !94 = !{!35, !35, i64 0}
|
||||
// CHECK:STDOUT: !89 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.4954785a8b134801:core.Destroy.Core", scope: null, file: !69, line: 7, type: !75, spFlags: DISPFlagDefinition, unit: !70, retainedNodes: !92)
|
||||
// CHECK:STDOUT: !90 = !DILocalVariable(arg: 1, scope: !89, type: !71)
|
||||
// CHECK:STDOUT: !91 = !DILocation(line: 7, column: 14, scope: !89)
|
||||
// CHECK:STDOUT: !92 = !{!90}
|
||||
// CHECK:STDOUT: !93 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.4954785a8b134801:core.Destroy.Core", scope: null, file: !69, line: 7, type: !75, spFlags: DISPFlagDefinition, unit: !70, retainedNodes: !96)
|
||||
// CHECK:STDOUT: !94 = !DILocalVariable(arg: 1, scope: !93, type: !71)
|
||||
// CHECK:STDOUT: !95 = !DILocation(line: 7, column: 14, scope: !93)
|
||||
// CHECK:STDOUT: !96 = !{!94}
|
||||
// CHECK:STDOUT: !97 = !{!"p1 _ZTS9NeedThunk", !36, i64 0}
|
||||
// CHECK:STDOUT: !98 = !{!97, !97, i64 0}
|
||||
// CHECK:STDOUT: !99 = !{!"p1 omnipotent char", !36, i64 0}
|
||||
// CHECK:STDOUT: !100 = !{!99, !99, i64 0}
|
||||
// CHECK:STDOUT: !102 = !{!35, !35, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; ---
|
||||
// CHECK:STDOUT: ; ModuleID = 'call_with_ref_self.carbon'
|
||||
@@ -441,10 +462,10 @@ fn F(ref r: Cpp.RefSelfA) {
|
||||
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF.Main(ptr %r) #0 !dbg !99 {
|
||||
// CHECK:STDOUT: define void @_CF.Main(ptr %r) #0 !dbg !107 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_ZN8RefSelfA1fEii(ptr %r, i32 1, i32 2), !dbg !102
|
||||
// CHECK:STDOUT: ret void, !dbg !103
|
||||
// CHECK:STDOUT: call void @_ZN8RefSelfA1fEii(ptr %r, i32 1, i32 2), !dbg !110
|
||||
// CHECK:STDOUT: ret void, !dbg !111
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_ZN8RefSelfA1fEii(ptr noundef nonnull align 1 dereferenceable(1), i32 noundef, i32 noundef) #1
|
||||
@@ -452,7 +473,7 @@ fn F(ref r: Cpp.RefSelfA) {
|
||||
// CHECK:STDOUT: attributes #0 = { nounwind }
|
||||
// CHECK:STDOUT: attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!96}
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!104}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!45, !46, !47, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!49}
|
||||
// CHECK:STDOUT:
|
||||
@@ -469,11 +490,11 @@ fn F(ref r: Cpp.RefSelfA) {
|
||||
// CHECK:STDOUT: !47 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !48 = !{!"__libc_errno", !40, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{!48, !40, i64 0}
|
||||
// CHECK:STDOUT: !95 = !DIFile(filename: "call_with_ref_self.carbon", directory: "")
|
||||
// CHECK:STDOUT: !96 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !95, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !99 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main", scope: null, file: !95, line: 11, type: !25, spFlags: DISPFlagDefinition, unit: !96, retainedNodes: !104)
|
||||
// CHECK:STDOUT: !100 = !DILocalVariable(arg: 1, scope: !99, type: !21)
|
||||
// CHECK:STDOUT: !102 = !DILocation(line: 12, column: 3, scope: !99)
|
||||
// CHECK:STDOUT: !103 = !DILocation(line: 11, column: 1, scope: !99)
|
||||
// CHECK:STDOUT: !104 = !{!100}
|
||||
// CHECK:STDOUT: !103 = !DIFile(filename: "call_with_ref_self.carbon", directory: "")
|
||||
// CHECK:STDOUT: !104 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !103, producer: "carbon", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug)
|
||||
// CHECK:STDOUT: !107 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main", scope: null, file: !103, line: 11, type: !25, spFlags: DISPFlagDefinition, unit: !104, retainedNodes: !112)
|
||||
// CHECK:STDOUT: !108 = !DILocalVariable(arg: 1, scope: !107, type: !21)
|
||||
// CHECK:STDOUT: !110 = !DILocation(line: 12, column: 3, scope: !107)
|
||||
// CHECK:STDOUT: !111 = !DILocation(line: 11, column: 1, scope: !107)
|
||||
// CHECK:STDOUT: !112 = !{!108}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -127,6 +127,7 @@ fn AccessD(d: Cpp.D) -> i32 {
|
||||
// CHECK:STDOUT: %_.var = alloca [40 x i8], align 8, !dbg !29
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !29
|
||||
// CHECK:STDOUT: call void @_ZN1DC1Ev.carbon_thunk.(ptr %_.var), !dbg !30
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.87042109e4175f46:core.Destroy.Core"(ptr %_.var), !dbg !29
|
||||
// CHECK:STDOUT: ret void, !dbg !32
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -134,18 +135,24 @@ fn AccessD(d: Cpp.D) -> i32 {
|
||||
// CHECK:STDOUT: define internal void @_ZN1DC1Ev.carbon_thunk.(ptr noundef %return) #1 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !45
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !45
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !49
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !49
|
||||
// CHECK:STDOUT: call void @_ZN1DC1Ev(ptr noundef nonnull align 8 dereferenceable(32) %0)
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i32 @_CAccessD.Main(ptr %d) #0 !dbg !33 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.87042109e4175f46:core.Destroy.Core"(ptr %self) #0 !dbg !33 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc16_11.1.d = getelementptr inbounds nuw [40 x i8], ptr %d, i32 0, i32 28, !dbg !38
|
||||
// CHECK:STDOUT: %.loc16_11.2 = load i32, ptr %.loc16_11.1.d, align 4, !dbg !38
|
||||
// CHECK:STDOUT: ret i32 %.loc16_11.2, !dbg !39
|
||||
// CHECK:STDOUT: ret void, !dbg !35
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define i32 @_CAccessD.Main(ptr %d) #0 !dbg !37 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %.loc16_11.1.d = getelementptr inbounds nuw [40 x i8], ptr %d, i32 0, i32 28, !dbg !42
|
||||
// CHECK:STDOUT: %.loc16_11.2 = load i32, ptr %.loc16_11.1.d, align 4, !dbg !42
|
||||
// CHECK:STDOUT: ret i32 %.loc16_11.2, !dbg !43
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
@@ -155,16 +162,16 @@ fn AccessD(d: Cpp.D) -> i32 {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN1DC1Ev(ptr noundef nonnull align 8 dereferenceable(32) %this) unnamed_addr #3 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !45
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !49
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: %0 = getelementptr inbounds i8, ptr %this1, i64 32
|
||||
// CHECK:STDOUT: call void @_ZN1AC2Ev(ptr noundef nonnull align 4 dereferenceable(4) %0)
|
||||
// CHECK:STDOUT: call void @_ZN1BC2Ev(ptr noundef nonnull align 8 dereferenceable(12) %this1, ptr noundef getelementptr inbounds nuw (i8, ptr @_ZTT1D, i64 8))
|
||||
// CHECK:STDOUT: %1 = getelementptr inbounds i8, ptr %this1, i64 16
|
||||
// CHECK:STDOUT: call void @_ZN1CC2Ev(ptr noundef nonnull align 8 dereferenceable(12) %1, ptr noundef getelementptr inbounds nuw (i8, ptr @_ZTT1D, i64 16))
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-24, 0) ({ [3 x ptr], [3 x ptr] }, ptr @_ZTV1D, i32 0, i32 0, i32 3), ptr %this1, align 8, !tbaa !47
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-24, 0) ({ [3 x ptr], [3 x ptr] }, ptr @_ZTV1D, i32 0, i32 0, i32 3), ptr %this1, align 8, !tbaa !51
|
||||
// CHECK:STDOUT: %add.ptr = getelementptr inbounds i8, ptr %this1, i64 16
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-24, 0) ({ [3 x ptr], [3 x ptr] }, ptr @_ZTV1D, i32 0, i32 1, i32 3), ptr %add.ptr, align 8, !tbaa !47
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-24, 0) ({ [3 x ptr], [3 x ptr] }, ptr @_ZTV1D, i32 0, i32 1, i32 3), ptr %add.ptr, align 8, !tbaa !51
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -188,8 +195,8 @@ fn AccessD(d: Cpp.D) -> i32 {
|
||||
// CHECK:STDOUT: attributes #4 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!19}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!48, !49, !50, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!53}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!52, !53, !54, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!57}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -199,28 +206,34 @@ fn AccessD(d: Cpp.D) -> i32 {
|
||||
// CHECK:STDOUT: !21 = !{null}
|
||||
// CHECK:STDOUT: !22 = !DISubroutineType(types: !21)
|
||||
// CHECK:STDOUT: !23 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
|
||||
// CHECK:STDOUT: !24 = !{null, !23}
|
||||
// CHECK:STDOUT: !25 = !DISubroutineType(types: !24)
|
||||
// CHECK:STDOUT: !26 = !{!20, !23}
|
||||
// CHECK:STDOUT: !27 = !DISubroutineType(types: !26)
|
||||
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Make", linkageName: "_CMake.Main", scope: null, file: !18, line: 6, type: !22, spFlags: DISPFlagDefinition, unit: !19)
|
||||
// CHECK:STDOUT: !29 = !DILocation(line: 11, column: 3, scope: !28)
|
||||
// CHECK:STDOUT: !30 = !DILocation(line: 11, column: 18, scope: !28)
|
||||
// CHECK:STDOUT: !32 = !DILocation(line: 6, column: 1, scope: !28)
|
||||
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "AccessD", linkageName: "_CAccessD.Main", scope: null, file: !18, line: 14, type: !27, spFlags: DISPFlagDefinition, unit: !19, retainedNodes: !40)
|
||||
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.87042109e4175f46:core.Destroy.Core", scope: null, file: !18, line: 11, type: !25, spFlags: DISPFlagDefinition, unit: !19, retainedNodes: !36)
|
||||
// CHECK:STDOUT: !34 = !DILocalVariable(arg: 1, scope: !33, type: !23)
|
||||
// CHECK:STDOUT: !38 = !DILocation(line: 16, column: 10, scope: !33)
|
||||
// CHECK:STDOUT: !39 = !DILocation(line: 16, column: 3, scope: !33)
|
||||
// CHECK:STDOUT: !40 = !{!34}
|
||||
// CHECK:STDOUT: !41 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !42 = !{!"omnipotent char", !41, i64 0}
|
||||
// CHECK:STDOUT: !43 = !{!"any pointer", !42, i64 0}
|
||||
// CHECK:STDOUT: !44 = !{!"p1 _ZTS1D", !43, i64 0}
|
||||
// CHECK:STDOUT: !45 = !{!44, !44, i64 0}
|
||||
// CHECK:STDOUT: !46 = !{!"vtable pointer", !41, i64 0}
|
||||
// CHECK:STDOUT: !47 = !{!46, !46, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !49 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !50 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !51 = !{!"int", !42, i64 0}
|
||||
// CHECK:STDOUT: !52 = !{!"__libc_errno", !51, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!52, !51, i64 0}
|
||||
// CHECK:STDOUT: !35 = !DILocation(line: 11, column: 3, scope: !33)
|
||||
// CHECK:STDOUT: !36 = !{!34}
|
||||
// CHECK:STDOUT: !37 = distinct !DISubprogram(name: "AccessD", linkageName: "_CAccessD.Main", scope: null, file: !18, line: 14, type: !27, spFlags: DISPFlagDefinition, unit: !19, retainedNodes: !44)
|
||||
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 1, scope: !37, type: !23)
|
||||
// CHECK:STDOUT: !42 = !DILocation(line: 16, column: 10, scope: !37)
|
||||
// CHECK:STDOUT: !43 = !DILocation(line: 16, column: 3, scope: !37)
|
||||
// CHECK:STDOUT: !44 = !{!38}
|
||||
// CHECK:STDOUT: !45 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !46 = !{!"omnipotent char", !45, i64 0}
|
||||
// CHECK:STDOUT: !47 = !{!"any pointer", !46, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{!"p1 _ZTS1D", !47, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{!48, !48, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{!"vtable pointer", !45, i64 0}
|
||||
// CHECK:STDOUT: !51 = !{!50, !50, i64 0}
|
||||
// CHECK:STDOUT: !52 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !53 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !54 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !55 = !{!"int", !46, i64 0}
|
||||
// CHECK:STDOUT: !56 = !{!"__libc_errno", !55, i64 0}
|
||||
// CHECK:STDOUT: !57 = !{!56, !55, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
+107
-60
@@ -186,8 +186,8 @@ void delete_new_Base() {
|
||||
// CHECK:STDOUT: define internal void @_ZNK1A1FEv.carbon_thunk._(ptr noundef nonnull align 8 dereferenceable(8) %this) #5 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !71
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %this.addr, align 8, !tbaa !71, !nonnull !74, !align !75
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !87
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %this.addr, align 8, !tbaa !87, !nonnull !90, !align !91
|
||||
// CHECK:STDOUT: %vtable = load ptr, ptr %0, align 8, !tbaa !8
|
||||
// CHECK:STDOUT: %vfn = getelementptr inbounds ptr, ptr %vtable, i64 2
|
||||
// CHECK:STDOUT: %1 = load ptr, ptr %vfn, align 8
|
||||
@@ -207,7 +207,7 @@ void delete_new_Base() {
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.Final.Main"(ptr %self) #6 !dbg !37 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.28387b086eba9957:core.Destroy.Core"(ptr %self), !dbg !39
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.28387b086eba9957:core.Destroy.Core"(ptr %self), !dbg !39
|
||||
// CHECK:STDOUT: ret void, !dbg !39
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -215,53 +215,84 @@ void delete_new_Base() {
|
||||
// CHECK:STDOUT: declare void @_ZN1AD1Ev(ptr noundef nonnull align 8 dead_on_return(8) dereferenceable(8)) unnamed_addr #7
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.e9cc9e95545cc62f:core.Destroy.Core"(ptr %self) #8 !dbg !41 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.f2cd4feee22137a3:core.Destroy.Core"(ptr %self) #8 !dbg !41 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %A.cpp_destructor.call.vtable = load ptr, ptr %self, align 8, !dbg !43
|
||||
// CHECK:STDOUT: %A.cpp_destructor.call = getelementptr ptr, ptr %A.cpp_destructor.call.vtable, i32 0, !dbg !43
|
||||
// CHECK:STDOUT: %A.cpp_destructor.call.memptr.virtualfn = load ptr, ptr %A.cpp_destructor.call, align 8, !dbg !43
|
||||
// CHECK:STDOUT: call void %A.cpp_destructor.call.memptr.virtualfn(ptr %self), !dbg !43
|
||||
// CHECK:STDOUT: ret void, !dbg !43
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.28387b086eba9957:core.Destroy.Core"(ptr %self) #8 !dbg !45 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.e9cc9e95545cc62f:core.Destroy.Core"(ptr %self) #8 !dbg !45 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !47
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.Final.Main(ptr %self) #8 !dbg !49 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.e9cc9e95545cc62f:core.Destroy.Core"(ptr %self) #8 !dbg !49 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.Final.Main(ptr %self), !dbg !51
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.e9cc9e95545cc62f:core.Destroy.Core"(ptr %self), !dbg !51
|
||||
// CHECK:STDOUT: ret void, !dbg !51
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.28387b086eba9957:core.Destroy.Core"(ptr %self) #8 !dbg !53 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !55
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.28387b086eba9957:core.Destroy.Core"(ptr %self) #8 !dbg !57 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.28387b086eba9957:core.Destroy.Core"(ptr %self), !dbg !59
|
||||
// CHECK:STDOUT: ret void, !dbg !59
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.Final.Main(ptr %self) #8 !dbg !61 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.Final.Main(ptr %self), !dbg !63
|
||||
// CHECK:STDOUT: ret void, !dbg !63
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_CF.Base.Main(ptr)
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CF:thunk:A.Cpp:Base.Main"(ptr %self) #6 !dbg !53 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.Base.Main(ptr %self), !dbg !56
|
||||
// CHECK:STDOUT: ret void, !dbg !56
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.Base.Main"(ptr %self) #6 !dbg !58 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.294df737cd074d60:core.Destroy.Core"(ptr %self), !dbg !60
|
||||
// CHECK:STDOUT: ret void, !dbg !60
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.294df737cd074d60:core.Destroy.Core"(ptr %self) #8 !dbg !62 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !64
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.Base.Main(ptr %self) #8 !dbg !66 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CF:thunk:A.Cpp:Base.Main"(ptr %self) #6 !dbg !65 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.Base.Main(ptr %self), !dbg !68
|
||||
// CHECK:STDOUT: ret void, !dbg !68
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.Base.Main"(ptr %self) #6 !dbg !70 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.294df737cd074d60:core.Destroy.Core"(ptr %self), !dbg !72
|
||||
// CHECK:STDOUT: ret void, !dbg !72
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.294df737cd074d60:core.Destroy.Core"(ptr %self) #8 !dbg !74 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !76
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.294df737cd074d60:core.Destroy.Core"(ptr %self) #8 !dbg !78 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.294df737cd074d60:core.Destroy.Core"(ptr %self), !dbg !80
|
||||
// CHECK:STDOUT: ret void, !dbg !80
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF__carbon_thunk.Base.Main(ptr %self) #8 !dbg !82 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_CF.Base.Main(ptr %self), !dbg !84
|
||||
// CHECK:STDOUT: ret void, !dbg !84
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @__cxa_pure_virtual() unnamed_addr
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: declare void @_ZNK1A1FEv(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #9
|
||||
@@ -324,7 +355,7 @@ void delete_new_Base() {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN1AC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %this) unnamed_addr #3 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !71
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !87
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 24) ({ [5 x ptr] }, ptr @_ZTV1A, i32 0, i32 0, i32 2), ptr %this1, align 8, !tbaa !8
|
||||
// CHECK:STDOUT: ret void
|
||||
@@ -354,8 +385,8 @@ void delete_new_Base() {
|
||||
// CHECK:STDOUT: attributes #11 = { builtin nounwind }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!28}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!77, !78, !79, !11, !12}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!82}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!93, !94, !95, !11, !12}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!98}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !0 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !1 = !{!"omnipotent char", !0, i64 0}
|
||||
@@ -381,42 +412,58 @@ void delete_new_Base() {
|
||||
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 1, scope: !37, type: !29)
|
||||
// CHECK:STDOUT: !39 = !DILocation(line: 12, column: 1, scope: !37)
|
||||
// CHECK:STDOUT: !40 = !{!38}
|
||||
// CHECK:STDOUT: !41 = distinct !DISubprogram(name: "Op", linkageName: "_COp.e9cc9e95545cc62f:core.Destroy.Core", scope: null, file: !27, line: 12, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !44)
|
||||
// CHECK:STDOUT: !41 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.f2cd4feee22137a3:core.Destroy.Core", scope: null, file: !27, line: 12, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !44)
|
||||
// CHECK:STDOUT: !42 = !DILocalVariable(arg: 1, scope: !41, type: !29)
|
||||
// CHECK:STDOUT: !43 = !DILocation(line: 12, column: 1, scope: !41)
|
||||
// CHECK:STDOUT: !44 = !{!42}
|
||||
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Op", linkageName: "_COp.28387b086eba9957:core.Destroy.Core", scope: null, file: !27, line: 12, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !48)
|
||||
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.e9cc9e95545cc62f:core.Destroy.Core", scope: null, file: !27, line: 12, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !48)
|
||||
// CHECK:STDOUT: !46 = !DILocalVariable(arg: 1, scope: !45, type: !29)
|
||||
// CHECK:STDOUT: !47 = !DILocation(line: 12, column: 1, scope: !45)
|
||||
// CHECK:STDOUT: !48 = !{!46}
|
||||
// CHECK:STDOUT: !49 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.Final.Main", scope: null, file: !27, line: 14, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !52)
|
||||
// CHECK:STDOUT: !49 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.e9cc9e95545cc62f:core.Destroy.Core", scope: null, file: !27, line: 12, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !52)
|
||||
// CHECK:STDOUT: !50 = !DILocalVariable(arg: 1, scope: !49, type: !29)
|
||||
// CHECK:STDOUT: !51 = !DILocation(line: 14, column: 3, scope: !49)
|
||||
// CHECK:STDOUT: !51 = !DILocation(line: 12, column: 1, scope: !49)
|
||||
// CHECK:STDOUT: !52 = !{!50}
|
||||
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "F", linkageName: "_CF:thunk:A.Cpp:Base.Main", scope: null, file: !27, line: 19, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !57)
|
||||
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.28387b086eba9957:core.Destroy.Core", scope: null, file: !27, line: 12, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !56)
|
||||
// CHECK:STDOUT: !54 = !DILocalVariable(arg: 1, scope: !53, type: !29)
|
||||
// CHECK:STDOUT: !56 = !DILocation(line: 19, column: 3, scope: !53)
|
||||
// CHECK:STDOUT: !57 = !{!54}
|
||||
// CHECK:STDOUT: !58 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.Base.Main", scope: null, file: !27, line: 17, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !61)
|
||||
// CHECK:STDOUT: !59 = !DILocalVariable(arg: 1, scope: !58, type: !29)
|
||||
// CHECK:STDOUT: !60 = !DILocation(line: 17, column: 1, scope: !58)
|
||||
// CHECK:STDOUT: !61 = !{!59}
|
||||
// CHECK:STDOUT: !62 = distinct !DISubprogram(name: "Op", linkageName: "_COp.294df737cd074d60:core.Destroy.Core", scope: null, file: !27, line: 17, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !65)
|
||||
// CHECK:STDOUT: !63 = !DILocalVariable(arg: 1, scope: !62, type: !29)
|
||||
// CHECK:STDOUT: !64 = !DILocation(line: 17, column: 1, scope: !62)
|
||||
// CHECK:STDOUT: !65 = !{!63}
|
||||
// CHECK:STDOUT: !66 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.Base.Main", scope: null, file: !27, line: 19, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !69)
|
||||
// CHECK:STDOUT: !67 = !DILocalVariable(arg: 1, scope: !66, type: !29)
|
||||
// CHECK:STDOUT: !68 = !DILocation(line: 19, column: 3, scope: !66)
|
||||
// CHECK:STDOUT: !69 = !{!67}
|
||||
// CHECK:STDOUT: !70 = !{!"p1 _ZTS1A", !2, i64 0}
|
||||
// CHECK:STDOUT: !71 = !{!70, !70, i64 0}
|
||||
// CHECK:STDOUT: !74 = !{}
|
||||
// CHECK:STDOUT: !75 = !{i64 8}
|
||||
// CHECK:STDOUT: !77 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !78 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !79 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !80 = !{!"int", !1, i64 0}
|
||||
// CHECK:STDOUT: !81 = !{!"__libc_errno", !80, i64 0}
|
||||
// CHECK:STDOUT: !82 = !{!81, !80, i64 0}
|
||||
// CHECK:STDOUT: !55 = !DILocation(line: 12, column: 1, scope: !53)
|
||||
// CHECK:STDOUT: !56 = !{!54}
|
||||
// CHECK:STDOUT: !57 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.28387b086eba9957:core.Destroy.Core", scope: null, file: !27, line: 12, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !60)
|
||||
// CHECK:STDOUT: !58 = !DILocalVariable(arg: 1, scope: !57, type: !29)
|
||||
// CHECK:STDOUT: !59 = !DILocation(line: 12, column: 1, scope: !57)
|
||||
// CHECK:STDOUT: !60 = !{!58}
|
||||
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.Final.Main", scope: null, file: !27, line: 14, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !64)
|
||||
// CHECK:STDOUT: !62 = !DILocalVariable(arg: 1, scope: !61, type: !29)
|
||||
// CHECK:STDOUT: !63 = !DILocation(line: 14, column: 3, scope: !61)
|
||||
// CHECK:STDOUT: !64 = !{!62}
|
||||
// CHECK:STDOUT: !65 = distinct !DISubprogram(name: "F", linkageName: "_CF:thunk:A.Cpp:Base.Main", scope: null, file: !27, line: 19, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !69)
|
||||
// CHECK:STDOUT: !66 = !DILocalVariable(arg: 1, scope: !65, type: !29)
|
||||
// CHECK:STDOUT: !68 = !DILocation(line: 19, column: 3, scope: !65)
|
||||
// CHECK:STDOUT: !69 = !{!66}
|
||||
// CHECK:STDOUT: !70 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.Base.Main", scope: null, file: !27, line: 17, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !73)
|
||||
// CHECK:STDOUT: !71 = !DILocalVariable(arg: 1, scope: !70, type: !29)
|
||||
// CHECK:STDOUT: !72 = !DILocation(line: 17, column: 1, scope: !70)
|
||||
// CHECK:STDOUT: !73 = !{!71}
|
||||
// CHECK:STDOUT: !74 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.294df737cd074d60:core.Destroy.Core", scope: null, file: !27, line: 17, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !77)
|
||||
// CHECK:STDOUT: !75 = !DILocalVariable(arg: 1, scope: !74, type: !29)
|
||||
// CHECK:STDOUT: !76 = !DILocation(line: 17, column: 1, scope: !74)
|
||||
// CHECK:STDOUT: !77 = !{!75}
|
||||
// CHECK:STDOUT: !78 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.294df737cd074d60:core.Destroy.Core", scope: null, file: !27, line: 17, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !81)
|
||||
// CHECK:STDOUT: !79 = !DILocalVariable(arg: 1, scope: !78, type: !29)
|
||||
// CHECK:STDOUT: !80 = !DILocation(line: 17, column: 1, scope: !78)
|
||||
// CHECK:STDOUT: !81 = !{!79}
|
||||
// CHECK:STDOUT: !82 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.Base.Main", scope: null, file: !27, line: 19, type: !31, spFlags: DISPFlagDefinition, unit: !28, retainedNodes: !85)
|
||||
// CHECK:STDOUT: !83 = !DILocalVariable(arg: 1, scope: !82, type: !29)
|
||||
// CHECK:STDOUT: !84 = !DILocation(line: 19, column: 3, scope: !82)
|
||||
// CHECK:STDOUT: !85 = !{!83}
|
||||
// CHECK:STDOUT: !86 = !{!"p1 _ZTS1A", !2, i64 0}
|
||||
// CHECK:STDOUT: !87 = !{!86, !86, i64 0}
|
||||
// CHECK:STDOUT: !90 = !{}
|
||||
// CHECK:STDOUT: !91 = !{i64 8}
|
||||
// CHECK:STDOUT: !93 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !94 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !95 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !96 = !{!"int", !1, i64 0}
|
||||
// CHECK:STDOUT: !97 = !{!"__libc_errno", !96, i64 0}
|
||||
// CHECK:STDOUT: !98 = !{!97, !96, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -59,7 +59,7 @@ fn F() {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN1X1fEv(ptr noundef nonnull align 8 dereferenceable(8) %this) unnamed_addr #0 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !49
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !61
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
@@ -80,49 +80,69 @@ fn F() {
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_C__destroy_thunk:thunk.Z.Main"(ptr %self) #2 !dbg !23 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_COp.680f7fa3ef86df7a:core.Destroy.Core"(ptr %self), !dbg !25
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.680f7fa3ef86df7a:core.Destroy.Core"(ptr %self), !dbg !25
|
||||
// CHECK:STDOUT: ret void, !dbg !25
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.de73a19002e400c9:core.Destroy.Core"(ptr %self) #1 !dbg !27 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.3d7b8a41b4c67e71:core.Destroy.Core"(ptr %self) #1 !dbg !27 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !29
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_COp.680f7fa3ef86df7a:core.Destroy.Core"(ptr %self) #1 !dbg !31 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.de73a19002e400c9:core.Destroy.Core"(ptr %self) #1 !dbg !31 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: ret void, !dbg !33
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_Cf__carbon_thunk.Z.Main(ptr %self) #1 !dbg !35 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.de73a19002e400c9:core.Destroy.Core"(ptr %self) #1 !dbg !35 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Cf.Z.Main(ptr %self), !dbg !37
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.de73a19002e400c9:core.Destroy.Core"(ptr %self), !dbg !37
|
||||
// CHECK:STDOUT: ret void, !dbg !37
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF.Main() #1 !dbg !39 {
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSubobjectDestroy.680f7fa3ef86df7a:core.Destroy.Core"(ptr %self) #1 !dbg !39 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %_.var = alloca { [8 x i8] }, align 8, !dbg !40
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !40
|
||||
// CHECK:STDOUT: %.loc24_32.1.base = getelementptr inbounds nuw { [8 x i8] }, ptr %_.var, i32 0, i32 0, !dbg !41
|
||||
// CHECK:STDOUT: call void @_ZN1XC1Ev.carbon_thunk.(ptr %.loc24_32.1.base), !dbg !42
|
||||
// CHECK:STDOUT: %.loc24_32.7.base = getelementptr inbounds nuw { [8 x i8] }, ptr %_.var, i32 0, i32 0, !dbg !41
|
||||
// CHECK:STDOUT: %.loc24_32.8.vptr = getelementptr inbounds nuw [8 x i8], ptr %.loc24_32.7.base, i32 0, i32 0, !dbg !41
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 8) ({ [3 x ptr] }, ptr @_ZTVN6Carbon1ZE, i32 0, i32 0, i32 2), ptr %.loc24_32.8.vptr, align 8, !dbg !41
|
||||
// CHECK:STDOUT: call void @"_COp.680f7fa3ef86df7a:core.Destroy.Core"(ptr %_.var), !dbg !40
|
||||
// CHECK:STDOUT: ret void, !dbg !44
|
||||
// CHECK:STDOUT: ret void, !dbg !41
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define weak_odr void @"_CSelfDestruct.680f7fa3ef86df7a:core.Destroy.Core"(ptr %self) #1 !dbg !43 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @"_CSubobjectDestroy.680f7fa3ef86df7a:core.Destroy.Core"(ptr %self), !dbg !45
|
||||
// CHECK:STDOUT: ret void, !dbg !45
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_Cf__carbon_thunk.Z.Main(ptr %self) #1 !dbg !47 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: call void @_Cf.Z.Main(ptr %self), !dbg !49
|
||||
// CHECK:STDOUT: ret void, !dbg !49
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define void @_CF.Main() #1 !dbg !51 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %_.var = alloca { [8 x i8] }, align 8, !dbg !52
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !52
|
||||
// CHECK:STDOUT: %.loc24_32.1.base = getelementptr inbounds nuw { [8 x i8] }, ptr %_.var, i32 0, i32 0, !dbg !53
|
||||
// CHECK:STDOUT: call void @_ZN1XC1Ev.carbon_thunk.(ptr %.loc24_32.1.base), !dbg !54
|
||||
// CHECK:STDOUT: %.loc24_32.7.base = getelementptr inbounds nuw { [8 x i8] }, ptr %_.var, i32 0, i32 0, !dbg !53
|
||||
// CHECK:STDOUT: %.loc24_32.8.vptr = getelementptr inbounds nuw [8 x i8], ptr %.loc24_32.7.base, i32 0, i32 0, !dbg !53
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 8) ({ [3 x ptr] }, ptr @_ZTVN6Carbon1ZE, i32 0, i32 0, i32 2), ptr %.loc24_32.8.vptr, align 8, !dbg !53
|
||||
// CHECK:STDOUT: call void @"_CSelfDestruct.680f7fa3ef86df7a:core.Destroy.Core"(ptr %_.var), !dbg !52
|
||||
// CHECK:STDOUT: ret void, !dbg !56
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
|
||||
// CHECK:STDOUT: define internal void @_ZN1XC1Ev.carbon_thunk.(ptr noundef %return) #3 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !49
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !49
|
||||
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !61
|
||||
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !61
|
||||
// CHECK:STDOUT: call void @_ZN1XC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %0) #1
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
@@ -134,7 +154,7 @@ fn F() {
|
||||
// CHECK:STDOUT: define internal void @_ZN6Carbon1Z1fEv(ptr noundef nonnull align 8 dereferenceable(8) %this) unnamed_addr #3 align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !53
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !65
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: call void @_Cf__carbon_thunk.Z.Main(ptr noundef nonnull align 8 dereferenceable(8) %this1)
|
||||
// CHECK:STDOUT: ret void
|
||||
@@ -144,9 +164,9 @@ fn F() {
|
||||
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN1XC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %this) unnamed_addr #5 comdat align 2 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: %this.addr = alloca ptr, align 8
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !49
|
||||
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !61
|
||||
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 8) ({ [3 x ptr] }, ptr @_ZTV1X, i32 0, i32 0, i32 2), ptr %this1, align 8, !tbaa !51
|
||||
// CHECK:STDOUT: store ptr getelementptr inbounds inrange(-16, 8) ({ [3 x ptr] }, ptr @_ZTV1X, i32 0, i32 0, i32 2), ptr %this1, align 8, !tbaa !63
|
||||
// CHECK:STDOUT: ret void
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -158,8 +178,8 @@ fn F() {
|
||||
// CHECK:STDOUT: attributes #5 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !llvm.dbg.cu = !{!7}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!56, !57, !58, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!61}
|
||||
// CHECK:STDOUT: !llvm.module.flags = !{!68, !69, !70, !2, !3}
|
||||
// CHECK:STDOUT: !llvm.errno.tbaa = !{!73}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !2 = !{i32 7, !"Dwarf Version", i32 5}
|
||||
// CHECK:STDOUT: !3 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
@@ -182,36 +202,48 @@ fn F() {
|
||||
// CHECK:STDOUT: !24 = !DILocalVariable(arg: 1, scope: !23, type: !8)
|
||||
// CHECK:STDOUT: !25 = !DILocation(line: 18, column: 1, scope: !23)
|
||||
// CHECK:STDOUT: !26 = !{!24}
|
||||
// CHECK:STDOUT: !27 = distinct !DISubprogram(name: "Op", linkageName: "_COp.de73a19002e400c9:core.Destroy.Core", scope: null, file: !6, line: 18, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !30)
|
||||
// CHECK:STDOUT: !27 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.3d7b8a41b4c67e71:core.Destroy.Core", scope: null, file: !6, line: 18, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !30)
|
||||
// CHECK:STDOUT: !28 = !DILocalVariable(arg: 1, scope: !27, type: !8)
|
||||
// CHECK:STDOUT: !29 = !DILocation(line: 18, column: 1, scope: !27)
|
||||
// CHECK:STDOUT: !30 = !{!28}
|
||||
// CHECK:STDOUT: !31 = distinct !DISubprogram(name: "Op", linkageName: "_COp.680f7fa3ef86df7a:core.Destroy.Core", scope: null, file: !6, line: 18, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !34)
|
||||
// CHECK:STDOUT: !31 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.de73a19002e400c9:core.Destroy.Core", scope: null, file: !6, line: 18, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !34)
|
||||
// CHECK:STDOUT: !32 = !DILocalVariable(arg: 1, scope: !31, type: !8)
|
||||
// CHECK:STDOUT: !33 = !DILocation(line: 18, column: 1, scope: !31)
|
||||
// CHECK:STDOUT: !34 = !{!32}
|
||||
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "f__carbon_thunk", linkageName: "_Cf__carbon_thunk.Z.Main", scope: null, file: !6, line: 20, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !38)
|
||||
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.de73a19002e400c9:core.Destroy.Core", scope: null, file: !6, line: 18, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !38)
|
||||
// CHECK:STDOUT: !36 = !DILocalVariable(arg: 1, scope: !35, type: !8)
|
||||
// CHECK:STDOUT: !37 = !DILocation(line: 20, column: 3, scope: !35)
|
||||
// CHECK:STDOUT: !37 = !DILocation(line: 18, column: 1, scope: !35)
|
||||
// CHECK:STDOUT: !38 = !{!36}
|
||||
// CHECK:STDOUT: !39 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main", scope: null, file: !6, line: 23, type: !12, spFlags: DISPFlagDefinition, unit: !7)
|
||||
// CHECK:STDOUT: !40 = !DILocation(line: 24, column: 3, scope: !39)
|
||||
// CHECK:STDOUT: !41 = !DILocation(line: 24, column: 14, scope: !39)
|
||||
// CHECK:STDOUT: !42 = !DILocation(line: 24, column: 23, scope: !39)
|
||||
// CHECK:STDOUT: !44 = !DILocation(line: 23, column: 1, scope: !39)
|
||||
// CHECK:STDOUT: !45 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !46 = !{!"omnipotent char", !45, i64 0}
|
||||
// CHECK:STDOUT: !47 = !{!"any pointer", !46, i64 0}
|
||||
// CHECK:STDOUT: !48 = !{!"p1 _ZTS1X", !47, i64 0}
|
||||
// CHECK:STDOUT: !49 = !{!48, !48, i64 0}
|
||||
// CHECK:STDOUT: !50 = !{!"vtable pointer", !45, i64 0}
|
||||
// CHECK:STDOUT: !51 = !{!50, !50, i64 0}
|
||||
// CHECK:STDOUT: !52 = !{!"p1 _ZTSN6Carbon1ZE", !47, i64 0}
|
||||
// CHECK:STDOUT: !53 = !{!52, !52, i64 0}
|
||||
// CHECK:STDOUT: !56 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !57 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !58 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !59 = !{!"int", !46, i64 0}
|
||||
// CHECK:STDOUT: !60 = !{!"__libc_errno", !59, i64 0}
|
||||
// CHECK:STDOUT: !61 = !{!60, !59, i64 0}
|
||||
// CHECK:STDOUT: !39 = distinct !DISubprogram(name: "SubobjectDestroy", linkageName: "_CSubobjectDestroy.680f7fa3ef86df7a:core.Destroy.Core", scope: null, file: !6, line: 18, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !42)
|
||||
// CHECK:STDOUT: !40 = !DILocalVariable(arg: 1, scope: !39, type: !8)
|
||||
// CHECK:STDOUT: !41 = !DILocation(line: 18, column: 1, scope: !39)
|
||||
// CHECK:STDOUT: !42 = !{!40}
|
||||
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "SelfDestruct", linkageName: "_CSelfDestruct.680f7fa3ef86df7a:core.Destroy.Core", scope: null, file: !6, line: 18, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !46)
|
||||
// CHECK:STDOUT: !44 = !DILocalVariable(arg: 1, scope: !43, type: !8)
|
||||
// CHECK:STDOUT: !45 = !DILocation(line: 18, column: 1, scope: !43)
|
||||
// CHECK:STDOUT: !46 = !{!44}
|
||||
// CHECK:STDOUT: !47 = distinct !DISubprogram(name: "f__carbon_thunk", linkageName: "_Cf__carbon_thunk.Z.Main", scope: null, file: !6, line: 20, type: !10, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !50)
|
||||
// CHECK:STDOUT: !48 = !DILocalVariable(arg: 1, scope: !47, type: !8)
|
||||
// CHECK:STDOUT: !49 = !DILocation(line: 20, column: 3, scope: !47)
|
||||
// CHECK:STDOUT: !50 = !{!48}
|
||||
// CHECK:STDOUT: !51 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main", scope: null, file: !6, line: 23, type: !12, spFlags: DISPFlagDefinition, unit: !7)
|
||||
// CHECK:STDOUT: !52 = !DILocation(line: 24, column: 3, scope: !51)
|
||||
// CHECK:STDOUT: !53 = !DILocation(line: 24, column: 14, scope: !51)
|
||||
// CHECK:STDOUT: !54 = !DILocation(line: 24, column: 23, scope: !51)
|
||||
// CHECK:STDOUT: !56 = !DILocation(line: 23, column: 1, scope: !51)
|
||||
// CHECK:STDOUT: !57 = !{!"Simple C++ TBAA"}
|
||||
// CHECK:STDOUT: !58 = !{!"omnipotent char", !57, i64 0}
|
||||
// CHECK:STDOUT: !59 = !{!"any pointer", !58, i64 0}
|
||||
// CHECK:STDOUT: !60 = !{!"p1 _ZTS1X", !59, i64 0}
|
||||
// CHECK:STDOUT: !61 = !{!60, !60, i64 0}
|
||||
// CHECK:STDOUT: !62 = !{!"vtable pointer", !57, i64 0}
|
||||
// CHECK:STDOUT: !63 = !{!62, !62, i64 0}
|
||||
// CHECK:STDOUT: !64 = !{!"p1 _ZTSN6Carbon1ZE", !59, i64 0}
|
||||
// CHECK:STDOUT: !65 = !{!64, !64, i64 0}
|
||||
// CHECK:STDOUT: !68 = !{i32 8, !"PIC Level", i32 2}
|
||||
// CHECK:STDOUT: !69 = !{i32 7, !"PIE Level", i32 2}
|
||||
// CHECK:STDOUT: !70 = !{i32 7, !"uwtable", i32 2}
|
||||
// CHECK:STDOUT: !71 = !{!"int", !58, i64 0}
|
||||
// CHECK:STDOUT: !72 = !{!"__libc_errno", !71, i64 0}
|
||||
// CHECK:STDOUT: !73 = !{!72, !71, i64 0}
|
||||
// CHECK:STDOUT:
|
||||
|
||||
Reference in New Issue
Block a user