Update to a more recent LLVM. (#7488)

Fix a few API issues. There's also a newly-added file in compiler-rt
that is not supposed to be built by default but is not being excluded
properly by a glob. Added a patch to exclude that and sent
https://github.com/llvm/llvm-project/pull/208861 upstream.
This commit is contained in:
Richard Smith
2026-07-13 22:29:39 +00:00
committed by GitHub
parent 8ea32187d4
commit 8bae79f44a
46 changed files with 5222 additions and 5072 deletions
@@ -161,7 +161,7 @@ fn H() { Cpp.G2(); }
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.addr = alloca i8, align 1
// CHECK:STDOUT: %storedv = zext i1 %0 to i8
// CHECK:STDOUT: store i8 %storedv, ptr %.addr, align 1, !tbaa !11
// CHECK:STDOUT: store i8 %storedv, ptr %.addr, align 1, !tbaa !12
// CHECK:STDOUT: call void @_CBoolArg__carbon_thunk.Other(ptr noundef nonnull align 1 dereferenceable(1) %.addr)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
@@ -170,7 +170,7 @@ fn H() { Cpp.G2(); }
// CHECK:STDOUT: define internal void @_ZN6Carbon5OtherL6IntArgEi(i32 noundef %0) #1 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.addr = alloca i32, align 4
// CHECK:STDOUT: store i32 %0, ptr %.addr, align 4, !tbaa !7
// CHECK:STDOUT: store i32 %0, ptr %.addr, align 4, !tbaa !14
// CHECK:STDOUT: call void @_CIntArg__carbon_thunk.Other(ptr noundef nonnull align 4 dereferenceable(4) %.addr)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
@@ -179,7 +179,7 @@ fn H() { Cpp.G2(); }
// CHECK:STDOUT: define internal void @_ZN6Carbon5OtherL8FloatArgEf(float noundef %0) #1 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.addr = alloca float, align 4
// CHECK:STDOUT: store float %0, ptr %.addr, align 4, !tbaa !13
// CHECK:STDOUT: store float %0, ptr %.addr, align 4, !tbaa !15
// CHECK:STDOUT: call void @_CFloatArg__carbon_thunk.Other(ptr noundef nonnull align 4 dereferenceable(4) %.addr)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
@@ -196,51 +196,51 @@ fn H() { Cpp.G2(); }
// CHECK:STDOUT: declare void @_CNoArgs.Other()
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CNoArgs__carbon_thunk.Other() #2 !dbg !15 {
// CHECK:STDOUT: define void @_CNoArgs__carbon_thunk.Other() #2 !dbg !17 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CNoArgs.Other(), !dbg !19
// CHECK:STDOUT: ret void, !dbg !19
// CHECK:STDOUT: call void @_CNoArgs.Other(), !dbg !21
// CHECK:STDOUT: ret void, !dbg !21
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_CBoolArg.Other(i1)
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CBoolArg__carbon_thunk.Other(ptr %_) #2 !dbg !20 {
// CHECK:STDOUT: define void @_CBoolArg__carbon_thunk.Other(ptr %_) #2 !dbg !22 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.1 = load i8, ptr %_, align 1, !dbg !26
// CHECK:STDOUT: %.11 = trunc i8 %.1 to i1, !dbg !26
// CHECK:STDOUT: call void @_CBoolArg.Other(i1 %.11), !dbg !26
// CHECK:STDOUT: ret void, !dbg !26
// CHECK:STDOUT: %.1 = load i8, ptr %_, align 1, !dbg !28
// CHECK:STDOUT: %.11 = trunc i8 %.1 to i1, !dbg !28
// CHECK:STDOUT: call void @_CBoolArg.Other(i1 %.11), !dbg !28
// CHECK:STDOUT: ret void, !dbg !28
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_CIntArg.Other(i32)
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CIntArg__carbon_thunk.Other(ptr %_) #2 !dbg !27 {
// CHECK:STDOUT: define void @_CIntArg__carbon_thunk.Other(ptr %_) #2 !dbg !29 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.1 = load i32, ptr %_, align 4, !dbg !33
// CHECK:STDOUT: call void @_CIntArg.Other(i32 %.1), !dbg !33
// CHECK:STDOUT: ret void, !dbg !33
// CHECK:STDOUT: %.1 = load i32, ptr %_, align 4, !dbg !35
// CHECK:STDOUT: call void @_CIntArg.Other(i32 %.1), !dbg !35
// CHECK:STDOUT: ret void, !dbg !35
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_CFloatArg.Other(float)
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CFloatArg__carbon_thunk.Other(ptr %_) #2 !dbg !34 {
// CHECK:STDOUT: define void @_CFloatArg__carbon_thunk.Other(ptr %_) #2 !dbg !36 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.1 = load float, ptr %_, align 4, !dbg !37
// CHECK:STDOUT: call void @_CFloatArg.Other(float %.1), !dbg !37
// CHECK:STDOUT: ret void, !dbg !37
// CHECK:STDOUT: %.1 = load float, ptr %_, align 4, !dbg !39
// CHECK:STDOUT: call void @_CFloatArg.Other(float %.1), !dbg !39
// CHECK:STDOUT: ret void, !dbg !39
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare i32 @_CIntReturn.Other()
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CIntReturn__carbon_thunk.Other(ptr %_) #2 !dbg !38 {
// CHECK:STDOUT: define void @_CIntReturn__carbon_thunk.Other(ptr %_) #2 !dbg !40 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %IntReturn.call = call i32 @_CIntReturn.Other(), !dbg !41
// CHECK:STDOUT: store i32 %IntReturn.call, ptr %_, align 4, !dbg !41
// CHECK:STDOUT: ret void, !dbg !41
// CHECK:STDOUT: %IntReturn.call = call i32 @_CIntReturn.Other(), !dbg !43
// CHECK:STDOUT: store i32 %IntReturn.call, ptr %_, align 4, !dbg !43
// CHECK:STDOUT: ret void, !dbg !43
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: attributes #0 = { mustprogress 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" }
@@ -258,41 +258,43 @@ fn H() { Cpp.G2(); }
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = !{!12, !12, i64 0}
// CHECK:STDOUT: !12 = !{!"bool", !9, i64 0}
// CHECK:STDOUT: !13 = !{!14, !14, i64 0}
// CHECK:STDOUT: !14 = !{!"float", !9, i64 0}
// CHECK:STDOUT: !15 = distinct !DISubprogram(name: "NoArgs__carbon_thunk", linkageName: "_CNoArgs__carbon_thunk.Other", scope: null, file: !16, line: 2, type: !17, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !16 = !DIFile(filename: "other.carbon", directory: "")
// CHECK:STDOUT: !17 = !DISubroutineType(types: !18)
// CHECK:STDOUT: !18 = !{null}
// CHECK:STDOUT: !19 = !DILocation(line: 2, column: 1, scope: !15)
// CHECK:STDOUT: !20 = distinct !DISubprogram(name: "BoolArg__carbon_thunk", linkageName: "_CBoolArg__carbon_thunk.Other", scope: null, file: !16, line: 3, type: !21, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !24)
// CHECK:STDOUT: !21 = !DISubroutineType(types: !22)
// CHECK:STDOUT: !22 = !{null, !23}
// CHECK:STDOUT: !23 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !24 = !{!25}
// CHECK:STDOUT: !25 = !DILocalVariable(arg: 1, scope: !20, type: !23)
// CHECK:STDOUT: !26 = !DILocation(line: 3, column: 1, scope: !20)
// CHECK:STDOUT: !27 = distinct !DISubprogram(name: "IntArg__carbon_thunk", linkageName: "_CIntArg__carbon_thunk.Other", scope: null, file: !16, line: 6, type: !28, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !31)
// CHECK:STDOUT: !28 = !DISubroutineType(types: !29)
// CHECK:STDOUT: !29 = !{null, !30}
// CHECK:STDOUT: !30 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !31 = !{!32}
// CHECK:STDOUT: !32 = !DILocalVariable(arg: 1, scope: !27, type: !30)
// CHECK:STDOUT: !33 = !DILocation(line: 6, column: 1, scope: !27)
// CHECK:STDOUT: !34 = distinct !DISubprogram(name: "FloatArg__carbon_thunk", linkageName: "_CFloatArg__carbon_thunk.Other", scope: null, file: !16, line: 9, type: !21, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !35)
// CHECK:STDOUT: !35 = !{!36}
// CHECK:STDOUT: !36 = !DILocalVariable(arg: 1, scope: !34, type: !23)
// CHECK:STDOUT: !37 = !DILocation(line: 9, column: 1, scope: !34)
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "IntReturn__carbon_thunk", linkageName: "_CIntReturn__carbon_thunk.Other", scope: null, file: !16, line: 12, type: !28, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !39)
// CHECK:STDOUT: !39 = !{!40}
// CHECK:STDOUT: !40 = !DILocalVariable(arg: 1, scope: !38, type: !30)
// CHECK:STDOUT: !41 = !DILocation(line: 12, column: 1, scope: !38)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = !{!13, !13, i64 0}
// CHECK:STDOUT: !13 = !{!"bool", !10, i64 0}
// CHECK:STDOUT: !14 = !{!9, !9, i64 0}
// CHECK:STDOUT: !15 = !{!16, !16, i64 0}
// CHECK:STDOUT: !16 = !{!"float", !10, i64 0}
// CHECK:STDOUT: !17 = distinct !DISubprogram(name: "NoArgs__carbon_thunk", linkageName: "_CNoArgs__carbon_thunk.Other", scope: null, file: !18, line: 2, type: !19, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !18 = !DIFile(filename: "other.carbon", directory: "")
// CHECK:STDOUT: !19 = !DISubroutineType(types: !20)
// CHECK:STDOUT: !20 = !{null}
// CHECK:STDOUT: !21 = !DILocation(line: 2, column: 1, scope: !17)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "BoolArg__carbon_thunk", linkageName: "_CBoolArg__carbon_thunk.Other", scope: null, file: !18, line: 3, type: !23, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !26)
// CHECK:STDOUT: !23 = !DISubroutineType(types: !24)
// CHECK:STDOUT: !24 = !{null, !25}
// CHECK:STDOUT: !25 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !26 = !{!27}
// CHECK:STDOUT: !27 = !DILocalVariable(arg: 1, scope: !22, type: !25)
// CHECK:STDOUT: !28 = !DILocation(line: 3, column: 1, scope: !22)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "IntArg__carbon_thunk", linkageName: "_CIntArg__carbon_thunk.Other", scope: null, file: !18, line: 6, type: !30, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !33)
// CHECK:STDOUT: !30 = !DISubroutineType(types: !31)
// CHECK:STDOUT: !31 = !{null, !32}
// CHECK:STDOUT: !32 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !33 = !{!34}
// CHECK:STDOUT: !34 = !DILocalVariable(arg: 1, scope: !29, type: !32)
// CHECK:STDOUT: !35 = !DILocation(line: 6, column: 1, scope: !29)
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "FloatArg__carbon_thunk", linkageName: "_CFloatArg__carbon_thunk.Other", scope: null, file: !18, line: 9, type: !23, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !37)
// CHECK:STDOUT: !37 = !{!38}
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 1, scope: !36, type: !25)
// CHECK:STDOUT: !39 = !DILocation(line: 9, column: 1, scope: !36)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "IntReturn__carbon_thunk", linkageName: "_CIntReturn__carbon_thunk.Other", scope: null, file: !18, line: 12, type: !30, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !41)
// CHECK:STDOUT: !41 = !{!42}
// CHECK:STDOUT: !42 = !DILocalVariable(arg: 1, scope: !40, type: !32)
// CHECK:STDOUT: !43 = !DILocation(line: 12, column: 1, scope: !40)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'single_file.carbon'
@@ -305,23 +307,23 @@ fn H() { Cpp.G2(); }
// CHECK:STDOUT: $_Z2G1v = comdat any
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CF.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CF.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !14
// CHECK:STDOUT: ret void, !dbg !15
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CF__carbon_thunk.Main() #0 !dbg !15 {
// CHECK:STDOUT: define void @_CF__carbon_thunk.Main() #0 !dbg !16 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CF.Main(), !dbg !16
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: call void @_CF.Main(), !dbg !17
// CHECK:STDOUT: ret void, !dbg !17
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CH.Main() #0 !dbg !17 {
// CHECK:STDOUT: define void @_CH.Main() #0 !dbg !18 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z2G2v(), !dbg !18
// CHECK:STDOUT: ret void, !dbg !19
// CHECK:STDOUT: call void @_Z2G2v(), !dbg !19
// CHECK:STDOUT: ret void, !dbg !20
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: inlinehint mustprogress uwtable
@@ -360,17 +362,18 @@ fn H() { Cpp.G2(); }
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !15 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 1, scope: !15)
// CHECK:STDOUT: !17 = distinct !DISubprogram(name: "H", linkageName: "_CH.Main", scope: null, file: !1, line: 20, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !18 = !DILocation(line: 20, column: 10, scope: !17)
// CHECK:STDOUT: !19 = !DILocation(line: 20, column: 1, scope: !17)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT: !16 = distinct !DISubprogram(name: "F__carbon_thunk", linkageName: "_CF__carbon_thunk.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !17 = !DILocation(line: 6, column: 1, scope: !16)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "H", linkageName: "_CH.Main", scope: null, file: !1, line: 20, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !19 = !DILocation(line: 20, column: 10, scope: !18)
// CHECK:STDOUT: !20 = !DILocation(line: 20, column: 1, scope: !18)
// CHECK:STDOUT:
@@ -142,7 +142,7 @@ fn Run() {
// 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 !11
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !12
// 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
@@ -160,7 +160,7 @@ fn Run() {
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN6Carbon1BD2Ev(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 !14
// CHECK:STDOUT: store ptr %this, ptr %this.addr, align 8, !tbaa !15
// CHECK:STDOUT: %this1 = load ptr, ptr %this.addr, align 8
// CHECK:STDOUT: call void @"_C__destroy_thunk:thunk.B.Main"(ptr noundef nonnull align 1 %this1)
// CHECK:STDOUT: ret void
@@ -170,76 +170,76 @@ fn Run() {
// CHECK:STDOUT: declare void @llvm.lifetime.end.p0(ptr captures(none)) #1
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @"_CDoit.A.Main:I.Main"(ptr %self) #4 !dbg !16 {
// CHECK:STDOUT: define void @"_CDoit.A.Main:I.Main"(ptr %self) #4 !dbg !17 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !22
// CHECK:STDOUT: ret void, !dbg !23
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @"_CDoit.B.Main:I.Main"(ptr %self) #4 !dbg !23 {
// CHECK:STDOUT: define void @"_CDoit.B.Main:I.Main"(ptr %self) #4 !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !26
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.A.Main"(ptr %self) #5 !dbg !27 {
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.A.Main"(ptr %self) #5 !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.68011419f123494e:core.Destroy.Core"(ptr %self), !dbg !30
// CHECK:STDOUT: ret void, !dbg !30
// CHECK:STDOUT: call void @"_COp.68011419f123494e:core.Destroy.Core"(ptr %self), !dbg !31
// CHECK:STDOUT: ret void, !dbg !31
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.68011419f123494e:core.Destroy.Core"(ptr %self) #4 !dbg !31 {
// CHECK:STDOUT: define weak_odr void @"_COp.68011419f123494e:core.Destroy.Core"(ptr %self) #4 !dbg !32 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !34
// CHECK:STDOUT: ret void, !dbg !35
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.B.Main"(ptr %self) #5 !dbg !35 {
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.B.Main"(ptr %self) #5 !dbg !36 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.6c3865e9cbd9f6de:core.Destroy.Core"(ptr %self), !dbg !38
// CHECK:STDOUT: ret void, !dbg !38
// CHECK:STDOUT: call void @"_COp.6c3865e9cbd9f6de:core.Destroy.Core"(ptr %self), !dbg !39
// CHECK:STDOUT: ret void, !dbg !39
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.6c3865e9cbd9f6de:core.Destroy.Core"(ptr %self) #4 !dbg !39 {
// CHECK:STDOUT: define weak_odr void @"_COp.6c3865e9cbd9f6de:core.Destroy.Core"(ptr %self) #4 !dbg !40 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !42
// CHECK:STDOUT: ret void, !dbg !43
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CF__carbon_thunkinst70000035.Main(ptr %_) #4 !dbg !43 {
// CHECK:STDOUT: define void @_CF__carbon_thunkinst70000035.Main(ptr %_) #4 !dbg !44 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CF.Main.3e1f7ed08cd9ee58(ptr %_), !dbg !46
// CHECK:STDOUT: ret void, !dbg !46
// CHECK:STDOUT: call void @_CF.Main.3e1f7ed08cd9ee58(ptr %_), !dbg !47
// CHECK:STDOUT: ret void, !dbg !47
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CF__carbon_thunkinst70000050.Main(ptr %_) #4 !dbg !47 {
// CHECK:STDOUT: define void @_CF__carbon_thunkinst70000050.Main(ptr %_) #4 !dbg !48 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CF.Main.bd1b6d59f703c190(ptr %_), !dbg !50
// CHECK:STDOUT: ret void, !dbg !50
// CHECK:STDOUT: call void @_CF.Main.bd1b6d59f703c190(ptr %_), !dbg !51
// CHECK:STDOUT: ret void, !dbg !51
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i32 @main() #4 !dbg !51 {
// CHECK:STDOUT: define i32 @main() #4 !dbg !52 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z1Gv(), !dbg !55
// CHECK:STDOUT: ret i32 0, !dbg !56
// CHECK:STDOUT: call void @_Z1Gv(), !dbg !56
// CHECK:STDOUT: ret i32 0, !dbg !57
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.3e1f7ed08cd9ee58(ptr %t) #4 !dbg !57 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.3e1f7ed08cd9ee58(ptr %t) #4 !dbg !58 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_CDoit.A.Main:I.Main"(ptr %t), !dbg !60
// CHECK:STDOUT: ret void, !dbg !61
// CHECK:STDOUT: call void @"_CDoit.A.Main:I.Main"(ptr %t), !dbg !61
// CHECK:STDOUT: ret void, !dbg !62
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.bd1b6d59f703c190(ptr %t) #4 !dbg !62 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.bd1b6d59f703c190(ptr %t) #4 !dbg !63 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_CDoit.B.Main:I.Main"(ptr %t), !dbg !65
// CHECK:STDOUT: ret void, !dbg !66
// CHECK:STDOUT: call void @"_CDoit.B.Main:I.Main"(ptr %t), !dbg !66
// CHECK:STDOUT: ret void, !dbg !67
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; uselistorder directives
@@ -266,64 +266,65 @@ fn Run() {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = !{!12, !12, i64 0}
// CHECK:STDOUT: !12 = !{!"p1 _ZTSN6Carbon1AE", !13, i64 0}
// CHECK:STDOUT: !13 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !14 = !{!15, !15, i64 0}
// CHECK:STDOUT: !15 = !{!"p1 _ZTSN6Carbon1BE", !13, i64 0}
// CHECK:STDOUT: !16 = distinct !DISubprogram(name: "Doit", linkageName: "_CDoit.A.Main:I.Main", scope: null, file: !1, line: 10, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !20)
// CHECK:STDOUT: !17 = !DISubroutineType(types: !18)
// CHECK:STDOUT: !18 = !{null, !19}
// CHECK:STDOUT: !19 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !20 = !{!21}
// CHECK:STDOUT: !21 = !DILocalVariable(arg: 1, scope: !16, type: !19)
// CHECK:STDOUT: !22 = !DILocation(line: 10, column: 5, scope: !16)
// CHECK:STDOUT: !23 = distinct !DISubprogram(name: "Doit", linkageName: "_CDoit.B.Main:I.Main", scope: null, file: !1, line: 15, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !24)
// CHECK:STDOUT: !24 = !{!25}
// CHECK:STDOUT: !25 = !DILocalVariable(arg: 1, scope: !23, type: !19)
// CHECK:STDOUT: !26 = !DILocation(line: 15, column: 5, scope: !23)
// CHECK:STDOUT: !27 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.A.Main", scope: null, file: !1, line: 8, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !28)
// CHECK:STDOUT: !28 = !{!29}
// CHECK:STDOUT: !29 = !DILocalVariable(arg: 1, scope: !27, type: !19)
// CHECK:STDOUT: !30 = !DILocation(line: 8, column: 1, scope: !27)
// CHECK:STDOUT: !31 = distinct !DISubprogram(name: "Op", linkageName: "_COp.68011419f123494e:core.Destroy.Core", scope: null, file: !1, line: 8, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !32)
// CHECK:STDOUT: !32 = !{!33}
// CHECK:STDOUT: !33 = !DILocalVariable(arg: 1, scope: !31, type: !19)
// CHECK:STDOUT: !34 = !DILocation(line: 8, column: 1, scope: !31)
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.B.Main", scope: null, file: !1, line: 13, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !36)
// CHECK:STDOUT: !36 = !{!37}
// CHECK:STDOUT: !37 = !DILocalVariable(arg: 1, scope: !35, type: !19)
// CHECK:STDOUT: !38 = !DILocation(line: 13, column: 1, scope: !35)
// CHECK:STDOUT: !39 = distinct !DISubprogram(name: "Op", linkageName: "_COp.6c3865e9cbd9f6de:core.Destroy.Core", scope: null, file: !1, line: 13, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !40)
// CHECK:STDOUT: !40 = !{!41}
// CHECK:STDOUT: !41 = !DILocalVariable(arg: 1, scope: !39, type: !19)
// CHECK:STDOUT: !42 = !DILocation(line: 13, column: 1, scope: !39)
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "F__carbon_thunkinst70000035", linkageName: "_CF__carbon_thunkinst70000035.Main", scope: null, file: !1, line: 19, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !44)
// CHECK:STDOUT: !44 = !{!45}
// CHECK:STDOUT: !45 = !DILocalVariable(arg: 1, scope: !43, type: !19)
// CHECK:STDOUT: !46 = !DILocation(line: 19, column: 1, scope: !43)
// CHECK:STDOUT: !47 = distinct !DISubprogram(name: "F__carbon_thunkinst70000050", linkageName: "_CF__carbon_thunkinst70000050.Main", scope: null, file: !1, line: 19, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !48)
// CHECK:STDOUT: !48 = !{!49}
// CHECK:STDOUT: !49 = !DILocalVariable(arg: 1, scope: !47, type: !19)
// CHECK:STDOUT: !50 = !DILocation(line: 19, column: 1, scope: !47)
// CHECK:STDOUT: !51 = distinct !DISubprogram(name: "Run", linkageName: "main", scope: null, file: !1, line: 32, type: !52, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !52 = !DISubroutineType(types: !53)
// CHECK:STDOUT: !53 = !{!54}
// CHECK:STDOUT: !54 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !55 = !DILocation(line: 33, column: 3, scope: !51)
// CHECK:STDOUT: !56 = !DILocation(line: 32, column: 1, scope: !51)
// CHECK:STDOUT: !57 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.3e1f7ed08cd9ee58", scope: null, file: !1, line: 19, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !58)
// CHECK:STDOUT: !58 = !{!59}
// CHECK:STDOUT: !59 = !DILocalVariable(arg: 1, scope: !57, type: !19)
// CHECK:STDOUT: !60 = !DILocation(line: 20, column: 3, scope: !57)
// CHECK:STDOUT: !61 = !DILocation(line: 19, column: 1, scope: !57)
// CHECK:STDOUT: !62 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.bd1b6d59f703c190", scope: null, file: !1, line: 19, type: !17, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !63)
// CHECK:STDOUT: !63 = !{!64}
// CHECK:STDOUT: !64 = !DILocalVariable(arg: 1, scope: !62, type: !19)
// CHECK:STDOUT: !65 = !DILocation(line: 20, column: 3, scope: !62)
// CHECK:STDOUT: !66 = !DILocation(line: 19, column: 1, scope: !62)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = !{!13, !13, i64 0}
// CHECK:STDOUT: !13 = !{!"p1 _ZTSN6Carbon1AE", !14, i64 0}
// CHECK:STDOUT: !14 = !{!"any pointer", !10, i64 0}
// CHECK:STDOUT: !15 = !{!16, !16, i64 0}
// CHECK:STDOUT: !16 = !{!"p1 _ZTSN6Carbon1BE", !14, i64 0}
// CHECK:STDOUT: !17 = distinct !DISubprogram(name: "Doit", linkageName: "_CDoit.A.Main:I.Main", scope: null, file: !1, line: 10, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !21)
// CHECK:STDOUT: !18 = !DISubroutineType(types: !19)
// CHECK:STDOUT: !19 = !{null, !20}
// CHECK:STDOUT: !20 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !21 = !{!22}
// CHECK:STDOUT: !22 = !DILocalVariable(arg: 1, scope: !17, type: !20)
// CHECK:STDOUT: !23 = !DILocation(line: 10, column: 5, scope: !17)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Doit", linkageName: "_CDoit.B.Main:I.Main", scope: null, file: !1, line: 15, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !25)
// CHECK:STDOUT: !25 = !{!26}
// CHECK:STDOUT: !26 = !DILocalVariable(arg: 1, scope: !24, type: !20)
// CHECK:STDOUT: !27 = !DILocation(line: 15, column: 5, scope: !24)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.A.Main", scope: null, file: !1, line: 8, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !29)
// CHECK:STDOUT: !29 = !{!30}
// CHECK:STDOUT: !30 = !DILocalVariable(arg: 1, scope: !28, type: !20)
// CHECK:STDOUT: !31 = !DILocation(line: 8, column: 1, scope: !28)
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "Op", linkageName: "_COp.68011419f123494e:core.Destroy.Core", scope: null, file: !1, line: 8, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !33)
// CHECK:STDOUT: !33 = !{!34}
// CHECK:STDOUT: !34 = !DILocalVariable(arg: 1, scope: !32, type: !20)
// CHECK:STDOUT: !35 = !DILocation(line: 8, column: 1, scope: !32)
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "__destroy_thunk", linkageName: "_C__destroy_thunk:thunk.B.Main", scope: null, file: !1, line: 13, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !37)
// CHECK:STDOUT: !37 = !{!38}
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 1, scope: !36, type: !20)
// CHECK:STDOUT: !39 = !DILocation(line: 13, column: 1, scope: !36)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "Op", linkageName: "_COp.6c3865e9cbd9f6de:core.Destroy.Core", scope: null, file: !1, line: 13, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !41)
// CHECK:STDOUT: !41 = !{!42}
// CHECK:STDOUT: !42 = !DILocalVariable(arg: 1, scope: !40, type: !20)
// CHECK:STDOUT: !43 = !DILocation(line: 13, column: 1, scope: !40)
// CHECK:STDOUT: !44 = distinct !DISubprogram(name: "F__carbon_thunkinst70000035", linkageName: "_CF__carbon_thunkinst70000035.Main", scope: null, file: !1, line: 19, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !45)
// CHECK:STDOUT: !45 = !{!46}
// CHECK:STDOUT: !46 = !DILocalVariable(arg: 1, scope: !44, type: !20)
// CHECK:STDOUT: !47 = !DILocation(line: 19, column: 1, scope: !44)
// CHECK:STDOUT: !48 = distinct !DISubprogram(name: "F__carbon_thunkinst70000050", linkageName: "_CF__carbon_thunkinst70000050.Main", scope: null, file: !1, line: 19, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !49)
// CHECK:STDOUT: !49 = !{!50}
// CHECK:STDOUT: !50 = !DILocalVariable(arg: 1, scope: !48, type: !20)
// CHECK:STDOUT: !51 = !DILocation(line: 19, column: 1, scope: !48)
// CHECK:STDOUT: !52 = distinct !DISubprogram(name: "Run", linkageName: "main", scope: null, file: !1, line: 32, type: !53, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !53 = !DISubroutineType(types: !54)
// CHECK:STDOUT: !54 = !{!55}
// CHECK:STDOUT: !55 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !56 = !DILocation(line: 33, column: 3, scope: !52)
// CHECK:STDOUT: !57 = !DILocation(line: 32, column: 1, scope: !52)
// CHECK:STDOUT: !58 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.3e1f7ed08cd9ee58", scope: null, file: !1, line: 19, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !59)
// CHECK:STDOUT: !59 = !{!60}
// CHECK:STDOUT: !60 = !DILocalVariable(arg: 1, scope: !58, type: !20)
// CHECK:STDOUT: !61 = !DILocation(line: 20, column: 3, scope: !58)
// CHECK:STDOUT: !62 = !DILocation(line: 19, column: 1, scope: !58)
// CHECK:STDOUT: !63 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.bd1b6d59f703c190", scope: null, file: !1, line: 19, type: !18, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !64)
// CHECK:STDOUT: !64 = !{!65}
// CHECK:STDOUT: !65 = !DILocalVariable(arg: 1, scope: !63, type: !20)
// CHECK:STDOUT: !66 = !DILocation(line: 20, column: 3, scope: !63)
// CHECK:STDOUT: !67 = !DILocation(line: 19, column: 1, scope: !63)
// CHECK:STDOUT:
@@ -35,10 +35,10 @@ fn Run() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i32 @main() #1 !dbg !11 {
// CHECK:STDOUT: define i32 @main() #1 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN1N3RunEv(), !dbg !15
// CHECK:STDOUT: ret i32 0, !dbg !16
// CHECK:STDOUT: call void @_ZN1N3RunEv(), !dbg !16
// CHECK:STDOUT: ret i32 0, !dbg !17
// 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" }
@@ -55,14 +55,15 @@ fn Run() {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "Run", linkageName: "main", scope: null, file: !1, line: 8, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{!14}
// CHECK:STDOUT: !14 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !15 = !DILocation(line: 9, column: 3, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 8, column: 1, scope: !11)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "Run", linkageName: "main", scope: null, file: !1, line: 8, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{!15}
// CHECK:STDOUT: !15 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !16 = !DILocation(line: 9, column: 3, scope: !12)
// CHECK:STDOUT: !17 = !DILocation(line: 8, column: 1, scope: !12)
// CHECK:STDOUT:
@@ -139,10 +139,10 @@ fn MyF() -> i32 {
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z3foov(), !dbg !14
// CHECK:STDOUT: ret void, !dbg !15
// CHECK:STDOUT: call void @_Z3foov(), !dbg !15
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_Z3foov() #1
@@ -161,15 +161,16 @@ fn MyF() -> i32 {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 3, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'import_inline_function_decl.carbon'
@@ -180,10 +181,10 @@ fn MyF() -> i32 {
// CHECK:STDOUT: $_Z3foov = comdat any
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z3foov(), !dbg !14
// CHECK:STDOUT: ret void, !dbg !15
// CHECK:STDOUT: call void @_Z3foov(), !dbg !15
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: inlinehint mustprogress nounwind uwtable
@@ -206,15 +207,16 @@ fn MyF() -> i32 {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 3, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'import_inline_used_function_decl.carbon'
@@ -233,10 +235,10 @@ fn MyF() -> i32 {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CMyF.Main() #1 !dbg !11 {
// CHECK:STDOUT: define void @_CMyF.Main() #1 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z3foov(), !dbg !14
// CHECK:STDOUT: ret void, !dbg !15
// CHECK:STDOUT: call void @_Z3foov(), !dbg !15
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; uselistorder directives
@@ -256,15 +258,16 @@ fn MyF() -> i32 {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 3, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'import_multiple_inline_function_decls.carbon'
@@ -279,12 +282,12 @@ fn MyF() -> i32 {
// CHECK:STDOUT: $_Z4foo3v = comdat any
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z4foo1v(), !dbg !14
// CHECK:STDOUT: call void @_Z4foo2v(), !dbg !15
// CHECK:STDOUT: call void @_Z4foo3v(), !dbg !16
// CHECK:STDOUT: ret void, !dbg !17
// CHECK:STDOUT: call void @_Z4foo1v(), !dbg !15
// CHECK:STDOUT: call void @_Z4foo2v(), !dbg !16
// CHECK:STDOUT: call void @_Z4foo3v(), !dbg !17
// CHECK:STDOUT: ret void, !dbg !18
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: inlinehint mustprogress nounwind uwtable
@@ -319,17 +322,18 @@ fn MyF() -> i32 {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 8, column: 3, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 9, column: 3, scope: !11)
// CHECK:STDOUT: !17 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 3, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 8, column: 3, scope: !12)
// CHECK:STDOUT: !17 = !DILocation(line: 9, column: 3, scope: !12)
// CHECK:STDOUT: !18 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'import_inline_recursive_function_decl.carbon'
@@ -342,10 +346,10 @@ fn MyF() -> i32 {
// CHECK:STDOUT: $_Z4foo1v = comdat any
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z4foo2v(), !dbg !14
// CHECK:STDOUT: ret void, !dbg !15
// CHECK:STDOUT: call void @_Z4foo2v(), !dbg !15
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: inlinehint mustprogress uwtable
@@ -376,15 +380,16 @@ fn MyF() -> i32 {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 8, column: 3, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 8, column: 3, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'call_with_default_args.carbon'
@@ -393,22 +398,22 @@ fn MyF() -> i32 {
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i32 @_CMyF.Main() #0 !dbg !11 {
// CHECK:STDOUT: define i32 @_CMyF.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %value.var = alloca i32, align 4, !dbg !15
// CHECK:STDOUT: call void @_Z13NoReturnValueii.carbon_thunk.(), !dbg !16
// CHECK:STDOUT: call void @_Z13NoReturnValueii.carbon_thunk._(i32 3), !dbg !17
// CHECK:STDOUT: call void @_Z13NoReturnValueii(i32 3, i32 4), !dbg !18
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %value.var), !dbg !15
// CHECK:STDOUT: %SimpleReturnValue__carbon_thunk.call.loc11 = call i32 @_Z17SimpleReturnValueii.carbon_thunk.(), !dbg !19
// CHECK:STDOUT: store i32 %SimpleReturnValue__carbon_thunk.call.loc11, ptr %value.var, align 4, !dbg !15
// CHECK:STDOUT: %SimpleReturnValue__carbon_thunk.call.loc12 = call i32 @_Z17SimpleReturnValueii.carbon_thunk._(i32 3), !dbg !20
// CHECK:STDOUT: store i32 %SimpleReturnValue__carbon_thunk.call.loc12, ptr %value.var, align 4, !dbg !21
// CHECK:STDOUT: %SimpleReturnValue.call = call i32 @_Z17SimpleReturnValueii(i32 3, i32 4), !dbg !22
// CHECK:STDOUT: store i32 %SimpleReturnValue.call, ptr %value.var, align 4, !dbg !23
// CHECK:STDOUT: %.loc14 = load i32, ptr %value.var, align 4, !dbg !24
// CHECK:STDOUT: call void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %value.var), !dbg !15
// CHECK:STDOUT: ret i32 %.loc14, !dbg !25
// CHECK:STDOUT: %value.var = alloca i32, align 4, !dbg !16
// CHECK:STDOUT: call void @_Z13NoReturnValueii.carbon_thunk.(), !dbg !17
// CHECK:STDOUT: call void @_Z13NoReturnValueii.carbon_thunk._(i32 3), !dbg !18
// CHECK:STDOUT: call void @_Z13NoReturnValueii(i32 3, i32 4), !dbg !19
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %value.var), !dbg !16
// CHECK:STDOUT: %SimpleReturnValue__carbon_thunk.call.loc11 = call i32 @_Z17SimpleReturnValueii.carbon_thunk.(), !dbg !20
// CHECK:STDOUT: store i32 %SimpleReturnValue__carbon_thunk.call.loc11, ptr %value.var, align 4, !dbg !16
// CHECK:STDOUT: %SimpleReturnValue__carbon_thunk.call.loc12 = call i32 @_Z17SimpleReturnValueii.carbon_thunk._(i32 3), !dbg !21
// CHECK:STDOUT: store i32 %SimpleReturnValue__carbon_thunk.call.loc12, ptr %value.var, align 4, !dbg !22
// CHECK:STDOUT: %SimpleReturnValue.call = call i32 @_Z17SimpleReturnValueii(i32 3, i32 4), !dbg !23
// CHECK:STDOUT: store i32 %SimpleReturnValue.call, ptr %value.var, align 4, !dbg !24
// CHECK:STDOUT: %.loc14 = load i32, ptr %value.var, align 4, !dbg !25
// CHECK:STDOUT: call void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %value.var), !dbg !16
// CHECK:STDOUT: ret i32 %.loc14, !dbg !26
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
@@ -422,8 +427,8 @@ fn MyF() -> i32 {
// CHECK:STDOUT: define internal void @_Z13NoReturnValueii.carbon_thunk._(i32 noundef %a) #1 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %a.addr = alloca i32, align 4
// CHECK:STDOUT: store i32 %a, ptr %a.addr, align 4, !tbaa !7
// CHECK:STDOUT: %0 = load i32, ptr %a.addr, align 4, !tbaa !7
// CHECK:STDOUT: store i32 %a, ptr %a.addr, align 4, !tbaa !27
// CHECK:STDOUT: %0 = load i32, ptr %a.addr, align 4, !tbaa !27
// CHECK:STDOUT: call void @_Z13NoReturnValueii(i32 noundef %0, i32 noundef 2)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
@@ -441,8 +446,8 @@ fn MyF() -> i32 {
// CHECK:STDOUT: define internal noundef i32 @_Z17SimpleReturnValueii.carbon_thunk._(i32 noundef %a) #1 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %a.addr = alloca i32, align 4
// CHECK:STDOUT: store i32 %a, ptr %a.addr, align 4, !tbaa !7
// CHECK:STDOUT: %0 = load i32, ptr %a.addr, align 4, !tbaa !7
// CHECK:STDOUT: store i32 %a, ptr %a.addr, align 4, !tbaa !27
// CHECK:STDOUT: %0 = load i32, ptr %a.addr, align 4, !tbaa !27
// CHECK:STDOUT: %call = call noundef i32 @_Z17SimpleReturnValueii(i32 noundef %0, i32 noundef 2)
// CHECK:STDOUT: ret i32 %call
// CHECK:STDOUT: }
@@ -450,9 +455,9 @@ fn MyF() -> i32 {
// CHECK:STDOUT: declare noundef i32 @_Z17SimpleReturnValueii(i32 noundef, i32 noundef) #2
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %self) #0 !dbg !26 {
// CHECK:STDOUT: define weak_odr void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %self) #0 !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !31
// CHECK:STDOUT: ret void, !dbg !33
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
@@ -478,29 +483,31 @@ fn MyF() -> i32 {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{!14}
// CHECK:STDOUT: !14 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !15 = !DILocation(line: 11, column: 3, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !17 = !DILocation(line: 8, column: 3, scope: !11)
// CHECK:STDOUT: !18 = !DILocation(line: 9, column: 3, scope: !11)
// CHECK:STDOUT: !19 = !DILocation(line: 11, column: 20, scope: !11)
// CHECK:STDOUT: !20 = !DILocation(line: 12, column: 11, scope: !11)
// CHECK:STDOUT: !21 = !DILocation(line: 12, column: 3, scope: !11)
// CHECK:STDOUT: !22 = !DILocation(line: 13, column: 11, scope: !11)
// CHECK:STDOUT: !23 = !DILocation(line: 13, column: 3, scope: !11)
// CHECK:STDOUT: !24 = !DILocation(line: 14, column: 10, scope: !11)
// CHECK:STDOUT: !25 = !DILocation(line: 14, column: 3, scope: !11)
// CHECK:STDOUT: !26 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5e27612b9dd31a14:core.Destroy.Core", scope: null, file: !1, line: 11, type: !27, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !29)
// CHECK:STDOUT: !27 = !DISubroutineType(types: !28)
// CHECK:STDOUT: !28 = !{null, !14}
// CHECK:STDOUT: !29 = !{!30}
// CHECK:STDOUT: !30 = !DILocalVariable(arg: 1, scope: !26, type: !14)
// CHECK:STDOUT: !31 = !DILocation(line: 11, column: 3, scope: !26)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{!15}
// CHECK:STDOUT: !15 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !16 = !DILocation(line: 11, column: 3, scope: !12)
// CHECK:STDOUT: !17 = !DILocation(line: 7, column: 3, scope: !12)
// CHECK:STDOUT: !18 = !DILocation(line: 8, column: 3, scope: !12)
// CHECK:STDOUT: !19 = !DILocation(line: 9, column: 3, scope: !12)
// CHECK:STDOUT: !20 = !DILocation(line: 11, column: 20, scope: !12)
// CHECK:STDOUT: !21 = !DILocation(line: 12, column: 11, scope: !12)
// CHECK:STDOUT: !22 = !DILocation(line: 12, column: 3, scope: !12)
// CHECK:STDOUT: !23 = !DILocation(line: 13, column: 11, scope: !12)
// CHECK:STDOUT: !24 = !DILocation(line: 13, column: 3, scope: !12)
// CHECK:STDOUT: !25 = !DILocation(line: 14, column: 10, scope: !12)
// CHECK:STDOUT: !26 = !DILocation(line: 14, column: 3, scope: !12)
// CHECK:STDOUT: !27 = !{!9, !9, i64 0}
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5e27612b9dd31a14:core.Destroy.Core", scope: null, file: !1, line: 11, type: !29, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !31)
// CHECK:STDOUT: !29 = !DISubroutineType(types: !30)
// CHECK:STDOUT: !30 = !{null, !15}
// CHECK:STDOUT: !31 = !{!32}
// CHECK:STDOUT: !32 = !DILocalVariable(arg: 1, scope: !28, type: !15)
// CHECK:STDOUT: !33 = !DILocation(line: 11, column: 3, scope: !28)
// CHECK:STDOUT:
@@ -39,17 +39,17 @@ fn F() {
// CHECK:STDOUT: $_ZN1XIiE1fEi = comdat any
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CF.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CF.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN1XIiE1fEi(i32 42), !dbg !14
// CHECK:STDOUT: ret void, !dbg !15
// CHECK:STDOUT: call void @_ZN1XIiE1fEi(i32 42), !dbg !15
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: mustprogress nounwind uwtable
// CHECK:STDOUT: define linkonce_odr dso_local void @_ZN1XIiE1fEi(i32 noundef %t) #1 comdat align 2 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %t.addr = alloca i32, align 4
// CHECK:STDOUT: store i32 %t, ptr %t.addr, align 4, !tbaa !7
// CHECK:STDOUT: store i32 %t, ptr %t.addr, align 4, !tbaa !17
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -67,13 +67,15 @@ fn F() {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 8, column: 3, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 8, column: 3, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT: !17 = !{!9, !9, i64 0}
// CHECK:STDOUT:
@@ -34,28 +34,28 @@ fn Call() -> i32 {
// CHECK:STDOUT: define dso_local void @_Z1FPi(ptr noundef %p) #0 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %p.addr = alloca ptr, align 8
// CHECK:STDOUT: store ptr %p, ptr %p.addr, align 8, !tbaa !11
// CHECK:STDOUT: %0 = load ptr, ptr %p.addr, align 8, !tbaa !11
// CHECK:STDOUT: store i32 1, ptr %0, align 4, !tbaa !7
// CHECK:STDOUT: store ptr %p, ptr %p.addr, align 8, !tbaa !12
// CHECK:STDOUT: %0 = load ptr, ptr %p.addr, align 8, !tbaa !12
// CHECK:STDOUT: store i32 1, ptr %0, align 4, !tbaa !15
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i32 @_CCall.Main() #1 !dbg !14 {
// CHECK:STDOUT: define i32 @_CCall.Main() #1 !dbg !16 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %n.var = alloca i32, align 4, !dbg !18
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %n.var), !dbg !18
// CHECK:STDOUT: store i32 0, ptr %n.var, align 4, !dbg !18
// CHECK:STDOUT: call void @_Z1FPi(ptr %n.var), !dbg !19
// CHECK:STDOUT: %.loc24 = load i32, ptr %n.var, align 4, !dbg !20
// CHECK:STDOUT: call void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %n.var), !dbg !18
// CHECK:STDOUT: ret i32 %.loc24, !dbg !21
// CHECK:STDOUT: %n.var = alloca i32, align 4, !dbg !20
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %n.var), !dbg !20
// CHECK:STDOUT: store i32 0, ptr %n.var, align 4, !dbg !20
// CHECK:STDOUT: call void @_Z1FPi(ptr %n.var), !dbg !21
// CHECK:STDOUT: %.loc24 = load i32, ptr %n.var, align 4, !dbg !22
// CHECK:STDOUT: call void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %n.var), !dbg !20
// CHECK:STDOUT: ret i32 %.loc24, !dbg !23
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %self) #1 !dbg !22 {
// CHECK:STDOUT: define weak_odr void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %self) #1 !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: ret void, !dbg !29
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
@@ -76,25 +76,27 @@ fn Call() -> i32 {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = !{!12, !12, i64 0}
// CHECK:STDOUT: !12 = !{!"p1 int", !13, i64 0}
// CHECK:STDOUT: !13 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !14 = distinct !DISubprogram(name: "Call", linkageName: "_CCall.Main", scope: null, file: !1, line: 21, type: !15, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !15 = !DISubroutineType(types: !16)
// CHECK:STDOUT: !16 = !{!17}
// CHECK:STDOUT: !17 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !18 = !DILocation(line: 22, column: 3, scope: !14)
// CHECK:STDOUT: !19 = !DILocation(line: 23, column: 3, scope: !14)
// CHECK:STDOUT: !20 = !DILocation(line: 24, column: 10, scope: !14)
// CHECK:STDOUT: !21 = !DILocation(line: 24, column: 3, scope: !14)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5e27612b9dd31a14:core.Destroy.Core", scope: null, file: !1, line: 22, type: !23, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !25)
// CHECK:STDOUT: !23 = !DISubroutineType(types: !24)
// CHECK:STDOUT: !24 = !{null, !17}
// CHECK:STDOUT: !25 = !{!26}
// CHECK:STDOUT: !26 = !DILocalVariable(arg: 1, scope: !22, type: !17)
// CHECK:STDOUT: !27 = !DILocation(line: 22, column: 3, scope: !22)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = !{!13, !13, i64 0}
// CHECK:STDOUT: !13 = !{!"p1 int", !14, i64 0}
// CHECK:STDOUT: !14 = !{!"any pointer", !10, i64 0}
// CHECK:STDOUT: !15 = !{!9, !9, i64 0}
// CHECK:STDOUT: !16 = distinct !DISubprogram(name: "Call", linkageName: "_CCall.Main", scope: null, file: !1, line: 21, type: !17, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !17 = !DISubroutineType(types: !18)
// CHECK:STDOUT: !18 = !{!19}
// CHECK:STDOUT: !19 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !20 = !DILocation(line: 22, column: 3, scope: !16)
// CHECK:STDOUT: !21 = !DILocation(line: 23, column: 3, scope: !16)
// CHECK:STDOUT: !22 = !DILocation(line: 24, column: 10, scope: !16)
// CHECK:STDOUT: !23 = !DILocation(line: 24, column: 3, scope: !16)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5e27612b9dd31a14:core.Destroy.Core", scope: null, file: !1, line: 22, type: !25, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !27)
// CHECK:STDOUT: !25 = !DISubroutineType(types: !26)
// CHECK:STDOUT: !26 = !{null, !19}
// CHECK:STDOUT: !27 = !{!28}
// CHECK:STDOUT: !28 = !DILocalVariable(arg: 1, scope: !24, type: !19)
// CHECK:STDOUT: !29 = !DILocation(line: 22, column: 3, scope: !24)
// CHECK:STDOUT:
@@ -122,23 +122,23 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: @llvm.global_ctors = appending global [1 x { i32, ptr, ptr }] [{ i32, ptr, ptr } { i32 0, ptr @_C__global_init.Main, ptr null }]
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CMyF.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc7_19.3.temp = alloca i8, align 1, !dbg !14
// CHECK:STDOUT: %.loc7_22.3.temp = alloca i16, align 2, !dbg !15
// CHECK:STDOUT: %.loc9_21.3.temp = alloca i8, align 1, !dbg !16
// CHECK:STDOUT: %.loc9_24.3.temp = alloca i16, align 2, !dbg !17
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_19.3.temp), !dbg !14
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_22.3.temp), !dbg !15
// CHECK:STDOUT: call void @_Z11pass_signedasil.carbon_thunk.____(ptr @int_1.f1e, ptr @int_2.5c2, i32 3, i64 4), !dbg !18
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc9_21.3.temp), !dbg !16
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc9_24.3.temp), !dbg !17
// CHECK:STDOUT: call void @_Z13pass_unsignedhtjm.carbon_thunk.____(ptr @int_1.067, ptr @int_2.ec3, i32 3, i64 4), !dbg !19
// CHECK:STDOUT: call void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr @int_2.ec3), !dbg !17
// CHECK:STDOUT: call void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr @int_1.067), !dbg !16
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr @int_2.5c2), !dbg !15
// CHECK:STDOUT: call void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr @int_1.f1e), !dbg !14
// CHECK:STDOUT: ret void, !dbg !20
// CHECK:STDOUT: %.loc7_19.3.temp = alloca i8, align 1, !dbg !15
// CHECK:STDOUT: %.loc7_22.3.temp = alloca i16, align 2, !dbg !16
// CHECK:STDOUT: %.loc9_21.3.temp = alloca i8, align 1, !dbg !17
// CHECK:STDOUT: %.loc9_24.3.temp = alloca i16, align 2, !dbg !18
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_19.3.temp), !dbg !15
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_22.3.temp), !dbg !16
// CHECK:STDOUT: call void @_Z11pass_signedasil.carbon_thunk.____(ptr @int_1.f1e, ptr @int_2.5c2, i32 3, i64 4), !dbg !19
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc9_21.3.temp), !dbg !17
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc9_24.3.temp), !dbg !18
// CHECK:STDOUT: call void @_Z13pass_unsignedhtjm.carbon_thunk.____(ptr @int_1.067, ptr @int_2.ec3, i32 3, i64 4), !dbg !20
// CHECK:STDOUT: call void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr @int_2.ec3), !dbg !18
// CHECK:STDOUT: call void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr @int_1.067), !dbg !17
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr @int_2.5c2), !dbg !16
// CHECK:STDOUT: call void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr @int_1.f1e), !dbg !15
// CHECK:STDOUT: ret void, !dbg !21
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
@@ -148,16 +148,16 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: %.addr1 = alloca ptr, align 8
// CHECK:STDOUT: %.addr2 = alloca i32, align 4
// CHECK:STDOUT: %.addr3 = alloca i64, align 8
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !21
// CHECK:STDOUT: store ptr %1, ptr %.addr1, align 8, !tbaa !24
// CHECK:STDOUT: store i32 %2, ptr %.addr2, align 4, !tbaa !7
// CHECK:STDOUT: store i64 %3, ptr %.addr3, align 8, !tbaa !26
// CHECK:STDOUT: %4 = load ptr, ptr %.addr, align 8, !tbaa !21
// CHECK:STDOUT: %5 = load i8, ptr %4, align 1, !tbaa !28
// CHECK:STDOUT: %6 = load ptr, ptr %.addr1, align 8, !tbaa !24
// CHECK:STDOUT: %7 = load i16, ptr %6, align 2, !tbaa !29
// CHECK:STDOUT: %8 = load i32, ptr %.addr2, align 4, !tbaa !7
// CHECK:STDOUT: %9 = load i64, ptr %.addr3, align 8, !tbaa !26
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !22
// CHECK:STDOUT: store ptr %1, ptr %.addr1, align 8, !tbaa !25
// CHECK:STDOUT: store i32 %2, ptr %.addr2, align 4, !tbaa !27
// CHECK:STDOUT: store i64 %3, ptr %.addr3, align 8, !tbaa !28
// CHECK:STDOUT: %4 = load ptr, ptr %.addr, align 8, !tbaa !22
// CHECK:STDOUT: %5 = load i8, ptr %4, align 1, !tbaa !30
// CHECK:STDOUT: %6 = load ptr, ptr %.addr1, align 8, !tbaa !25
// CHECK:STDOUT: %7 = load i16, ptr %6, align 2, !tbaa !31
// CHECK:STDOUT: %8 = load i32, ptr %.addr2, align 4, !tbaa !27
// CHECK:STDOUT: %9 = load i64, ptr %.addr3, align 8, !tbaa !28
// CHECK:STDOUT: call void @_Z11pass_signedasil(i8 noundef signext %5, i16 noundef signext %7, i32 noundef %8, i64 noundef %9)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
@@ -169,82 +169,82 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: %.addr1 = alloca ptr, align 8
// CHECK:STDOUT: %.addr2 = alloca i32, align 4
// CHECK:STDOUT: %.addr3 = alloca i64, align 8
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !21
// CHECK:STDOUT: store ptr %1, ptr %.addr1, align 8, !tbaa !24
// CHECK:STDOUT: store i32 %2, ptr %.addr2, align 4, !tbaa !7
// CHECK:STDOUT: store i64 %3, ptr %.addr3, align 8, !tbaa !26
// CHECK:STDOUT: %4 = load ptr, ptr %.addr, align 8, !tbaa !21
// CHECK:STDOUT: %5 = load i8, ptr %4, align 1, !tbaa !28
// CHECK:STDOUT: %6 = load ptr, ptr %.addr1, align 8, !tbaa !24
// CHECK:STDOUT: %7 = load i16, ptr %6, align 2, !tbaa !29
// CHECK:STDOUT: %8 = load i32, ptr %.addr2, align 4, !tbaa !7
// CHECK:STDOUT: %9 = load i64, ptr %.addr3, align 8, !tbaa !26
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !22
// CHECK:STDOUT: store ptr %1, ptr %.addr1, align 8, !tbaa !25
// CHECK:STDOUT: store i32 %2, ptr %.addr2, align 4, !tbaa !27
// CHECK:STDOUT: store i64 %3, ptr %.addr3, align 8, !tbaa !28
// CHECK:STDOUT: %4 = load ptr, ptr %.addr, align 8, !tbaa !22
// CHECK:STDOUT: %5 = load i8, ptr %4, align 1, !tbaa !30
// CHECK:STDOUT: %6 = load ptr, ptr %.addr1, align 8, !tbaa !25
// CHECK:STDOUT: %7 = load i16, ptr %6, align 2, !tbaa !31
// CHECK:STDOUT: %8 = load i32, ptr %.addr2, align 4, !tbaa !27
// CHECK:STDOUT: %9 = load i64, ptr %.addr3, align 8, !tbaa !28
// CHECK:STDOUT: call void @_Z13pass_unsignedhtjm(i8 noundef zeroext %5, i16 noundef zeroext %7, i32 noundef %8, i64 noundef %9)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr %self) #0 !dbg !31 {
// CHECK:STDOUT: define weak_odr void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr %self) #0 !dbg !33 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !37
// CHECK:STDOUT: ret void, !dbg !39
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr %self) #0 !dbg !38 {
// CHECK:STDOUT: define weak_odr void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr %self) #0 !dbg !40 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !44
// CHECK:STDOUT: ret void, !dbg !46
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %self) #0 !dbg !45 {
// CHECK:STDOUT: define weak_odr void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %self) #0 !dbg !47 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !51
// CHECK:STDOUT: ret void, !dbg !53
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr %self) #0 !dbg !52 {
// CHECK:STDOUT: define weak_odr void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr %self) #0 !dbg !54 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !58
// CHECK:STDOUT: ret void, !dbg !60
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare i16 @_CMakeShort.Main()
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CPassShort.Main(i16 %a, ptr %b) #0 !dbg !59 {
// CHECK:STDOUT: define void @_CPassShort.Main(i16 %a, ptr %b) #0 !dbg !61 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc17_18.1.temp = alloca i16, align 2, !dbg !66
// CHECK:STDOUT: %.loc18_18.3.temp = alloca i16, align 2, !dbg !67
// CHECK:STDOUT: %.loc19_18.2.temp = alloca i16, align 2, !dbg !68
// CHECK:STDOUT: %.loc20_28.3.temp = alloca i16, align 2, !dbg !69
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc17_18.1.temp), !dbg !66
// CHECK:STDOUT: store i16 %a, ptr %.loc17_18.1.temp, align 2, !dbg !66
// CHECK:STDOUT: call void @_Z10pass_shorts.carbon_thunk._(ptr %.loc17_18.1.temp), !dbg !70
// CHECK:STDOUT: %.loc18_18.2 = load i16, ptr %b, align 2, !dbg !67
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc18_18.3.temp), !dbg !67
// CHECK:STDOUT: store i16 %.loc18_18.2, ptr %.loc18_18.3.temp, align 2, !dbg !67
// CHECK:STDOUT: call void @_Z10pass_shorts.carbon_thunk._(ptr %.loc18_18.3.temp), !dbg !71
// CHECK:STDOUT: %.loc19_18.1 = load i16, ptr @_Cc.Main, align 2, !dbg !68
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc19_18.2.temp), !dbg !68
// CHECK:STDOUT: store i16 %.loc19_18.1, ptr %.loc19_18.2.temp, align 2, !dbg !68
// CHECK:STDOUT: call void @_Z10pass_shorts.carbon_thunk._(ptr %.loc19_18.2.temp), !dbg !72
// CHECK:STDOUT: %MakeShort.call = call i16 @_CMakeShort.Main(), !dbg !69
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_28.3.temp), !dbg !69
// CHECK:STDOUT: store i16 %MakeShort.call, ptr %.loc20_28.3.temp, align 2, !dbg !69
// CHECK:STDOUT: call void @_Z10pass_shorts.carbon_thunk._(ptr %.loc20_28.3.temp), !dbg !73
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc20_28.3.temp), !dbg !69
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc19_18.2.temp), !dbg !68
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc18_18.3.temp), !dbg !67
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc17_18.1.temp), !dbg !66
// CHECK:STDOUT: ret void, !dbg !74
// CHECK:STDOUT: %.loc17_18.1.temp = alloca i16, align 2, !dbg !68
// CHECK:STDOUT: %.loc18_18.3.temp = alloca i16, align 2, !dbg !69
// CHECK:STDOUT: %.loc19_18.2.temp = alloca i16, align 2, !dbg !70
// CHECK:STDOUT: %.loc20_28.3.temp = alloca i16, align 2, !dbg !71
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc17_18.1.temp), !dbg !68
// CHECK:STDOUT: store i16 %a, ptr %.loc17_18.1.temp, align 2, !dbg !68
// CHECK:STDOUT: call void @_Z10pass_shorts.carbon_thunk._(ptr %.loc17_18.1.temp), !dbg !72
// CHECK:STDOUT: %.loc18_18.2 = load i16, ptr %b, align 2, !dbg !69
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc18_18.3.temp), !dbg !69
// CHECK:STDOUT: store i16 %.loc18_18.2, ptr %.loc18_18.3.temp, align 2, !dbg !69
// CHECK:STDOUT: call void @_Z10pass_shorts.carbon_thunk._(ptr %.loc18_18.3.temp), !dbg !73
// CHECK:STDOUT: %.loc19_18.1 = load i16, ptr @_Cc.Main, align 2, !dbg !70
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc19_18.2.temp), !dbg !70
// CHECK:STDOUT: store i16 %.loc19_18.1, ptr %.loc19_18.2.temp, align 2, !dbg !70
// CHECK:STDOUT: call void @_Z10pass_shorts.carbon_thunk._(ptr %.loc19_18.2.temp), !dbg !74
// CHECK:STDOUT: %MakeShort.call = call i16 @_CMakeShort.Main(), !dbg !71
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_28.3.temp), !dbg !71
// CHECK:STDOUT: store i16 %MakeShort.call, ptr %.loc20_28.3.temp, align 2, !dbg !71
// CHECK:STDOUT: call void @_Z10pass_shorts.carbon_thunk._(ptr %.loc20_28.3.temp), !dbg !75
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc20_28.3.temp), !dbg !71
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc19_18.2.temp), !dbg !70
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc18_18.3.temp), !dbg !69
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc17_18.1.temp), !dbg !68
// CHECK:STDOUT: ret void, !dbg !76
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
// CHECK:STDOUT: define internal void @_Z10pass_shorts.carbon_thunk._(ptr noundef %0) #1 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.addr = alloca ptr, align 8
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !24
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !24
// CHECK:STDOUT: %2 = load i16, ptr %1, align 2, !tbaa !29
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !25
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !25
// CHECK:STDOUT: %2 = load i16, ptr %1, align 2, !tbaa !31
// CHECK:STDOUT: call void @_Z10pass_shorts(i16 noundef signext %2)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
@@ -253,10 +253,10 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #2
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define internal void @_C__global_init.Main() #0 !dbg !75 {
// CHECK:STDOUT: define internal void @_C__global_init.Main() #0 !dbg !77 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: store i16 poison, ptr @_Cc.Main, align 2, !dbg !76
// CHECK:STDOUT: ret void, !dbg !77
// CHECK:STDOUT: store i16 poison, ptr @_Cc.Main, align 2, !dbg !78
// CHECK:STDOUT: ret void, !dbg !79
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_Z11pass_signedasil(i8 noundef signext, i16 noundef signext, i32 noundef, i64 noundef) #3
@@ -285,77 +285,79 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 7, column: 19, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 22, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 9, column: 21, scope: !11)
// CHECK:STDOUT: !17 = !DILocation(line: 9, column: 24, scope: !11)
// CHECK:STDOUT: !18 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !19 = !DILocation(line: 9, column: 3, scope: !11)
// CHECK:STDOUT: !20 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !21 = !{!22, !22, i64 0}
// CHECK:STDOUT: !22 = !{!"p1 omnipotent char", !23, i64 0}
// CHECK:STDOUT: !23 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !24 = !{!25, !25, i64 0}
// CHECK:STDOUT: !25 = !{!"p1 short", !23, i64 0}
// CHECK:STDOUT: !26 = !{!27, !27, i64 0}
// CHECK:STDOUT: !27 = !{!"long", !9, i64 0}
// CHECK:STDOUT: !28 = !{!9, !9, i64 0}
// CHECK:STDOUT: !29 = !{!30, !30, i64 0}
// CHECK:STDOUT: !30 = !{!"short", !9, i64 0}
// CHECK:STDOUT: !31 = distinct !DISubprogram(name: "Op", linkageName: "_COp.6fd0ed7da7a22bb4:core.Destroy.Core", scope: null, file: !1, line: 9, type: !32, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !35)
// CHECK:STDOUT: !32 = !DISubroutineType(types: !33)
// CHECK:STDOUT: !33 = !{null, !34}
// CHECK:STDOUT: !34 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !35 = !{!36}
// CHECK:STDOUT: !36 = !DILocalVariable(arg: 1, scope: !31, type: !34)
// CHECK:STDOUT: !37 = !DILocation(line: 9, column: 24, scope: !31)
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "Op", linkageName: "_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core", scope: null, file: !1, line: 9, type: !39, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !42)
// CHECK:STDOUT: !39 = !DISubroutineType(types: !40)
// CHECK:STDOUT: !40 = !{null, !41}
// CHECK:STDOUT: !41 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !42 = !{!43}
// CHECK:STDOUT: !43 = !DILocalVariable(arg: 1, scope: !38, type: !41)
// CHECK:STDOUT: !44 = !DILocation(line: 9, column: 21, scope: !38)
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Op", linkageName: "_COp.eb6702152d47e49f:core.Destroy.Core", scope: null, file: !1, line: 7, type: !46, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !49)
// CHECK:STDOUT: !46 = !DISubroutineType(types: !47)
// CHECK:STDOUT: !47 = !{null, !48}
// CHECK:STDOUT: !48 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_signed)
// CHECK:STDOUT: !49 = !{!50}
// CHECK:STDOUT: !50 = !DILocalVariable(arg: 1, scope: !45, type: !48)
// CHECK:STDOUT: !51 = !DILocation(line: 7, column: 22, scope: !45)
// CHECK:STDOUT: !52 = distinct !DISubprogram(name: "Op", linkageName: "_COp.578b3934f85dbca6:core.Destroy.Core", scope: null, file: !1, line: 7, type: !53, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !56)
// CHECK:STDOUT: !53 = !DISubroutineType(types: !54)
// CHECK:STDOUT: !54 = !{null, !55}
// CHECK:STDOUT: !55 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_signed)
// CHECK:STDOUT: !56 = !{!57}
// CHECK:STDOUT: !57 = !DILocalVariable(arg: 1, scope: !52, type: !55)
// CHECK:STDOUT: !58 = !DILocation(line: 7, column: 19, scope: !52)
// CHECK:STDOUT: !59 = distinct !DISubprogram(name: "PassShort", linkageName: "_CPassShort.Main", scope: null, file: !1, line: 16, type: !60, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !63)
// CHECK:STDOUT: !60 = !DISubroutineType(types: !61)
// CHECK:STDOUT: !61 = !{null, !48, !62}
// CHECK:STDOUT: !62 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !63 = !{!64, !65}
// CHECK:STDOUT: !64 = !DILocalVariable(arg: 1, scope: !59, type: !48)
// CHECK:STDOUT: !65 = !DILocalVariable(arg: 2, scope: !59, type: !62)
// CHECK:STDOUT: !66 = !DILocation(line: 17, column: 18, scope: !59)
// CHECK:STDOUT: !67 = !DILocation(line: 18, column: 18, scope: !59)
// CHECK:STDOUT: !68 = !DILocation(line: 19, column: 18, scope: !59)
// CHECK:STDOUT: !69 = !DILocation(line: 20, column: 18, scope: !59)
// CHECK:STDOUT: !70 = !DILocation(line: 17, column: 3, scope: !59)
// CHECK:STDOUT: !71 = !DILocation(line: 18, column: 3, scope: !59)
// CHECK:STDOUT: !72 = !DILocation(line: 19, column: 3, scope: !59)
// CHECK:STDOUT: !73 = !DILocation(line: 20, column: 3, scope: !59)
// CHECK:STDOUT: !74 = !DILocation(line: 16, column: 1, scope: !59)
// CHECK:STDOUT: !75 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !1, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !76 = !DILocation(line: 14, column: 1, scope: !75)
// CHECK:STDOUT: !77 = !DILocation(line: 0, scope: !75)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "MyF", linkageName: "_CMyF.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 19, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 7, column: 22, scope: !12)
// CHECK:STDOUT: !17 = !DILocation(line: 9, column: 21, scope: !12)
// CHECK:STDOUT: !18 = !DILocation(line: 9, column: 24, scope: !12)
// CHECK:STDOUT: !19 = !DILocation(line: 7, column: 3, scope: !12)
// CHECK:STDOUT: !20 = !DILocation(line: 9, column: 3, scope: !12)
// CHECK:STDOUT: !21 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT: !22 = !{!23, !23, i64 0}
// CHECK:STDOUT: !23 = !{!"p1 omnipotent char", !24, i64 0}
// CHECK:STDOUT: !24 = !{!"any pointer", !10, i64 0}
// CHECK:STDOUT: !25 = !{!26, !26, i64 0}
// CHECK:STDOUT: !26 = !{!"p1 short", !24, i64 0}
// CHECK:STDOUT: !27 = !{!9, !9, i64 0}
// CHECK:STDOUT: !28 = !{!29, !29, i64 0}
// CHECK:STDOUT: !29 = !{!"long", !10, i64 0}
// CHECK:STDOUT: !30 = !{!10, !10, i64 0}
// CHECK:STDOUT: !31 = !{!32, !32, i64 0}
// CHECK:STDOUT: !32 = !{!"short", !10, i64 0}
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.6fd0ed7da7a22bb4:core.Destroy.Core", scope: null, file: !1, line: 9, type: !34, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !37)
// CHECK:STDOUT: !34 = !DISubroutineType(types: !35)
// CHECK:STDOUT: !35 = !{null, !36}
// CHECK:STDOUT: !36 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !37 = !{!38}
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 1, scope: !33, type: !36)
// CHECK:STDOUT: !39 = !DILocation(line: 9, column: 24, scope: !33)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "Op", linkageName: "_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core", scope: null, file: !1, line: 9, type: !41, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !44)
// CHECK:STDOUT: !41 = !DISubroutineType(types: !42)
// CHECK:STDOUT: !42 = !{null, !43}
// CHECK:STDOUT: !43 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !44 = !{!45}
// CHECK:STDOUT: !45 = !DILocalVariable(arg: 1, scope: !40, type: !43)
// CHECK:STDOUT: !46 = !DILocation(line: 9, column: 21, scope: !40)
// CHECK:STDOUT: !47 = distinct !DISubprogram(name: "Op", linkageName: "_COp.eb6702152d47e49f:core.Destroy.Core", scope: null, file: !1, line: 7, type: !48, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !51)
// CHECK:STDOUT: !48 = !DISubroutineType(types: !49)
// CHECK:STDOUT: !49 = !{null, !50}
// CHECK:STDOUT: !50 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_signed)
// CHECK:STDOUT: !51 = !{!52}
// CHECK:STDOUT: !52 = !DILocalVariable(arg: 1, scope: !47, type: !50)
// CHECK:STDOUT: !53 = !DILocation(line: 7, column: 22, scope: !47)
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "Op", linkageName: "_COp.578b3934f85dbca6:core.Destroy.Core", scope: null, file: !1, line: 7, type: !55, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !58)
// CHECK:STDOUT: !55 = !DISubroutineType(types: !56)
// CHECK:STDOUT: !56 = !{null, !57}
// CHECK:STDOUT: !57 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_signed)
// CHECK:STDOUT: !58 = !{!59}
// CHECK:STDOUT: !59 = !DILocalVariable(arg: 1, scope: !54, type: !57)
// CHECK:STDOUT: !60 = !DILocation(line: 7, column: 19, scope: !54)
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "PassShort", linkageName: "_CPassShort.Main", scope: null, file: !1, line: 16, type: !62, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !65)
// CHECK:STDOUT: !62 = !DISubroutineType(types: !63)
// CHECK:STDOUT: !63 = !{null, !50, !64}
// CHECK:STDOUT: !64 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !65 = !{!66, !67}
// CHECK:STDOUT: !66 = !DILocalVariable(arg: 1, scope: !61, type: !50)
// CHECK:STDOUT: !67 = !DILocalVariable(arg: 2, scope: !61, type: !64)
// CHECK:STDOUT: !68 = !DILocation(line: 17, column: 18, scope: !61)
// CHECK:STDOUT: !69 = !DILocation(line: 18, column: 18, scope: !61)
// CHECK:STDOUT: !70 = !DILocation(line: 19, column: 18, scope: !61)
// CHECK:STDOUT: !71 = !DILocation(line: 20, column: 18, scope: !61)
// CHECK:STDOUT: !72 = !DILocation(line: 17, column: 3, scope: !61)
// CHECK:STDOUT: !73 = !DILocation(line: 18, column: 3, scope: !61)
// CHECK:STDOUT: !74 = !DILocation(line: 19, column: 3, scope: !61)
// CHECK:STDOUT: !75 = !DILocation(line: 20, column: 3, scope: !61)
// CHECK:STDOUT: !76 = !DILocation(line: 16, column: 1, scope: !61)
// CHECK:STDOUT: !77 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !1, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !78 = !DILocation(line: 14, column: 1, scope: !77)
// CHECK:STDOUT: !79 = !DILocation(line: 0, scope: !77)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'import_struct.carbon'
@@ -366,35 +368,35 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: %struct.X = type { i32, i32, i32 }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CTest.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CTest.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %x.var = alloca [12 x i8], align 4, !dbg !14
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %x.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.102476b7ae87d0a1"(ptr %x.var), !dbg !14
// CHECK:STDOUT: %.loc8_4.a = getelementptr inbounds nuw [12 x i8], ptr %x.var, i32 0, i32 0, !dbg !15
// CHECK:STDOUT: store i32 1, ptr %.loc8_4.a, align 4, !dbg !15
// CHECK:STDOUT: %.loc9_4.b = getelementptr inbounds nuw [12 x i8], ptr %x.var, i32 0, i32 4, !dbg !16
// CHECK:STDOUT: store i32 2, ptr %.loc9_4.b, align 4, !dbg !16
// CHECK:STDOUT: %.loc10_4.c = getelementptr inbounds nuw [12 x i8], ptr %x.var, i32 0, i32 8, !dbg !17
// CHECK:STDOUT: store i32 3, ptr %.loc10_4.c, align 4, !dbg !17
// CHECK:STDOUT: call void @_Z11pass_struct1X.carbon_thunk._(ptr %x.var), !dbg !18
// CHECK:STDOUT: ret void, !dbg !19
// CHECK:STDOUT: %x.var = alloca [12 x i8], align 4, !dbg !15
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %x.var), !dbg !15
// CHECK:STDOUT: call void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.102476b7ae87d0a1"(ptr %x.var), !dbg !15
// CHECK:STDOUT: %.loc8_4.a = getelementptr inbounds nuw [12 x i8], ptr %x.var, i32 0, i32 0, !dbg !16
// CHECK:STDOUT: store i32 1, ptr %.loc8_4.a, align 4, !dbg !16
// CHECK:STDOUT: %.loc9_4.b = getelementptr inbounds nuw [12 x i8], ptr %x.var, i32 0, i32 4, !dbg !17
// CHECK:STDOUT: store i32 2, ptr %.loc9_4.b, align 4, !dbg !17
// CHECK:STDOUT: %.loc10_4.c = getelementptr inbounds nuw [12 x i8], ptr %x.var, i32 0, i32 8, !dbg !18
// CHECK:STDOUT: store i32 3, ptr %.loc10_4.c, align 4, !dbg !18
// CHECK:STDOUT: call void @_Z11pass_struct1X.carbon_thunk._(ptr %x.var), !dbg !19
// CHECK:STDOUT: ret void, !dbg !20
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress nounwind uwtable
// CHECK:STDOUT: define internal void @_ZN1XC1Ev.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 !20
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !20
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !21
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !21
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Default.eed9ddf3aaac414a.Core:X.Cpp"(ptr sret([12 x i8]) %return) #2 !dbg !23 {
// CHECK:STDOUT: define void @"_COp:thunk:Default.eed9ddf3aaac414a.Core:X.Cpp"(ptr sret([12 x i8]) %return) #2 !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN1XC1Ev.carbon_thunk.(ptr %return), !dbg !28
// CHECK:STDOUT: ret void, !dbg !28
// CHECK:STDOUT: call void @_ZN1XC1Ev.carbon_thunk.(ptr %return), !dbg !29
// CHECK:STDOUT: ret void, !dbg !29
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
@@ -403,9 +405,9 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: %.addr = alloca ptr, align 8
// CHECK:STDOUT: %agg.tmp = alloca %struct.X, align 4
// CHECK:STDOUT: %agg.tmp.coerce = alloca { i64, i32 }, align 4
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !20
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !20
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 4 %agg.tmp, ptr align 4 %1, i64 12, i1 false), !tbaa.struct !29
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !21
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !21
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 4 %agg.tmp, ptr align 4 %1, i64 12, i1 false), !tbaa.struct !30
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 4 %agg.tmp.coerce, ptr align 4 %agg.tmp, i64 12, i1 false)
// CHECK:STDOUT: %2 = getelementptr inbounds nuw { i64, i32 }, ptr %agg.tmp.coerce, i32 0, i32 0
// CHECK:STDOUT: %3 = load i64, ptr %2, align 4
@@ -419,9 +421,9 @@ fn PassValueExpr(y: Cpp.Y) {
// 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.102476b7ae87d0a1"(ptr sret([12 x i8]) %return) #0 !dbg !30 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.eed9ddf3aaac414a.Core:X.Cpp"(ptr %return), !dbg !32
// CHECK:STDOUT: ret void, !dbg !33
// CHECK:STDOUT: define linkonce_odr void @"_COp.51f3fb62cb986374:DefaultOrUnformed.Core.102476b7ae87d0a1"(ptr sret([12 x i8]) %return) #0 !dbg !32 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.eed9ddf3aaac414a.Core:X.Cpp"(ptr %return), !dbg !34
// CHECK:STDOUT: ret void, !dbg !35
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_Z11pass_struct1X(i64, i32) #5
@@ -450,33 +452,35 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "Test", linkageName: "_CTest.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 8, column: 3, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 9, column: 3, scope: !11)
// CHECK:STDOUT: !17 = !DILocation(line: 10, column: 3, scope: !11)
// CHECK:STDOUT: !18 = !DILocation(line: 11, column: 3, scope: !11)
// CHECK:STDOUT: !19 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !20 = !{!21, !21, i64 0}
// CHECK:STDOUT: !21 = !{!"p1 _ZTS1X", !22, i64 0}
// CHECK:STDOUT: !22 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !23 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.eed9ddf3aaac414a.Core:X.Cpp", scope: null, file: !24, line: 2, type: !25, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !24 = !DIFile(filename: "./struct.h", directory: "")
// CHECK:STDOUT: !25 = !DISubroutineType(types: !26)
// CHECK:STDOUT: !26 = !{!27}
// CHECK:STDOUT: !27 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !28 = !DILocation(line: 2, column: 8, scope: !23)
// CHECK:STDOUT: !29 = !{i64 0, i64 4, !7, i64 4, i64 4, !7, i64 8, i64 4, !7}
// CHECK:STDOUT: !30 = distinct !DISubprogram(name: "Op", linkageName: "_COp.51f3fb62cb986374:DefaultOrUnformed.Core.102476b7ae87d0a1", scope: null, file: !31, line: 9, type: !25, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !31 = !DIFile(filename: "min_prelude/parts/default.carbon", directory: "")
// CHECK:STDOUT: !32 = !DILocation(line: 9, column: 28, scope: !30)
// CHECK:STDOUT: !33 = !DILocation(line: 9, column: 21, scope: !30)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "Test", linkageName: "_CTest.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 3, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 8, column: 3, scope: !12)
// CHECK:STDOUT: !17 = !DILocation(line: 9, column: 3, scope: !12)
// CHECK:STDOUT: !18 = !DILocation(line: 10, column: 3, scope: !12)
// CHECK:STDOUT: !19 = !DILocation(line: 11, column: 3, scope: !12)
// CHECK:STDOUT: !20 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT: !21 = !{!22, !22, i64 0}
// CHECK:STDOUT: !22 = !{!"p1 _ZTS1X", !23, i64 0}
// CHECK:STDOUT: !23 = !{!"any pointer", !10, i64 0}
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.eed9ddf3aaac414a.Core:X.Cpp", scope: null, file: !25, line: 2, type: !26, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !25 = !DIFile(filename: "./struct.h", directory: "")
// CHECK:STDOUT: !26 = !DISubroutineType(types: !27)
// CHECK:STDOUT: !27 = !{!28}
// CHECK:STDOUT: !28 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !29 = !DILocation(line: 2, column: 8, scope: !24)
// CHECK:STDOUT: !30 = !{i64 0, i64 4, !31, i64 4, i64 4, !31, i64 8, i64 4, !31}
// CHECK:STDOUT: !31 = !{!9, !9, i64 0}
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "Op", linkageName: "_COp.51f3fb62cb986374:DefaultOrUnformed.Core.102476b7ae87d0a1", scope: null, file: !33, line: 9, type: !26, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !33 = !DIFile(filename: "min_prelude/parts/default.carbon", directory: "")
// CHECK:STDOUT: !34 = !DILocation(line: 9, column: 28, scope: !32)
// CHECK:STDOUT: !35 = !DILocation(line: 9, column: 21, scope: !32)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'import_class_with_nontrivial_copy.carbon'
@@ -487,18 +491,18 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: %class.Y = type { i32, i32, i32 }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CPassRefExpr.Main() #0 !dbg !11 {
// CHECK:STDOUT: define void @_CPassRefExpr.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %y.var = alloca [12 x i8], align 4, !dbg !14
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %y.var), !dbg !14
// CHECK:STDOUT: %.loc8_4.a = getelementptr inbounds nuw [12 x i8], ptr %y.var, i32 0, i32 0, !dbg !15
// CHECK:STDOUT: store i32 1, ptr %.loc8_4.a, align 4, !dbg !15
// CHECK:STDOUT: %.loc9_4.b = getelementptr inbounds nuw [12 x i8], ptr %y.var, i32 0, i32 4, !dbg !16
// CHECK:STDOUT: store i32 2, ptr %.loc9_4.b, align 4, !dbg !16
// CHECK:STDOUT: %.loc10_4.c = getelementptr inbounds nuw [12 x i8], ptr %y.var, i32 0, i32 8, !dbg !17
// CHECK:STDOUT: store i32 3, ptr %.loc10_4.c, align 4, !dbg !17
// CHECK:STDOUT: call void @_Z11pass_struct1Y.carbon_thunk._(ptr %y.var), !dbg !18
// CHECK:STDOUT: ret void, !dbg !19
// CHECK:STDOUT: %y.var = alloca [12 x i8], align 4, !dbg !15
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %y.var), !dbg !15
// CHECK:STDOUT: %.loc8_4.a = getelementptr inbounds nuw [12 x i8], ptr %y.var, i32 0, i32 0, !dbg !16
// CHECK:STDOUT: store i32 1, ptr %.loc8_4.a, align 4, !dbg !16
// CHECK:STDOUT: %.loc9_4.b = getelementptr inbounds nuw [12 x i8], ptr %y.var, i32 0, i32 4, !dbg !17
// CHECK:STDOUT: store i32 2, ptr %.loc9_4.b, align 4, !dbg !17
// CHECK:STDOUT: %.loc10_4.c = getelementptr inbounds nuw [12 x i8], ptr %y.var, i32 0, i32 8, !dbg !18
// CHECK:STDOUT: store i32 3, ptr %.loc10_4.c, align 4, !dbg !18
// CHECK:STDOUT: call void @_Z11pass_struct1Y.carbon_thunk._(ptr %y.var), !dbg !19
// CHECK:STDOUT: ret void, !dbg !20
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
@@ -506,36 +510,36 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.addr = alloca ptr, align 8
// CHECK:STDOUT: %agg.tmp = alloca %class.Y, align 4
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !20
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !20
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !21
// CHECK:STDOUT: %1 = load ptr, ptr %.addr, align 8, !tbaa !21
// CHECK:STDOUT: call void @_ZN1YC1ERKS_(ptr noundef nonnull align 4 dereferenceable(12) %agg.tmp, ptr noundef nonnull align 4 dereferenceable(12) %1)
// CHECK:STDOUT: call void @_Z11pass_struct1Y(ptr noundef dead_on_return %agg.tmp)
// CHECK:STDOUT: call void @_Z11pass_struct1Y(ptr noundef align 4 dead_on_return %agg.tmp)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_CMake.Main(ptr sret([12 x i8]))
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CPassInitExpr.Main() #0 !dbg !23 {
// CHECK:STDOUT: define void @_CPassInitExpr.Main() #0 !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc17_24.1.temp = alloca [12 x i8], align 4, !dbg !24
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc17_24.1.temp), !dbg !24
// CHECK:STDOUT: call void @_CMake.Main(ptr %.loc17_24.1.temp), !dbg !24
// CHECK:STDOUT: call void @_Z11pass_struct1Y.carbon_thunk._(ptr %.loc17_24.1.temp), !dbg !25
// CHECK:STDOUT: ret void, !dbg !26
// CHECK:STDOUT: %.loc17_24.1.temp = alloca [12 x i8], align 4, !dbg !25
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc17_24.1.temp), !dbg !25
// CHECK:STDOUT: call void @_CMake.Main(ptr %.loc17_24.1.temp), !dbg !25
// CHECK:STDOUT: call void @_Z11pass_struct1Y.carbon_thunk._(ptr %.loc17_24.1.temp), !dbg !26
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CPassValueExpr.Main(ptr %y) #0 !dbg !27 {
// CHECK:STDOUT: define void @_CPassValueExpr.Main(ptr %y) #0 !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z11pass_struct1Y.carbon_thunk._(ptr %y), !dbg !33
// CHECK:STDOUT: ret void, !dbg !34
// CHECK:STDOUT: call void @_Z11pass_struct1Y.carbon_thunk._(ptr %y), !dbg !34
// CHECK:STDOUT: ret void, !dbg !35
// 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)) #2
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_Z11pass_struct1Y(ptr noundef dead_on_return) #3
// CHECK:STDOUT: declare void @_Z11pass_struct1Y(ptr noundef align 4 dead_on_return) #3
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_ZN1YC1ERKS_(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #3
// CHECK:STDOUT:
@@ -558,32 +562,33 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "PassRefExpr", linkageName: "_CPassRefExpr.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{null}
// CHECK:STDOUT: !14 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 8, column: 3, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 9, column: 3, scope: !11)
// CHECK:STDOUT: !17 = !DILocation(line: 10, column: 3, scope: !11)
// CHECK:STDOUT: !18 = !DILocation(line: 11, column: 3, scope: !11)
// CHECK:STDOUT: !19 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !20 = !{!21, !21, i64 0}
// CHECK:STDOUT: !21 = !{!"p1 _ZTS1Y", !22, i64 0}
// CHECK:STDOUT: !22 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !23 = distinct !DISubprogram(name: "PassInitExpr", linkageName: "_CPassInitExpr.Main", scope: null, file: !1, line: 16, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !24 = !DILocation(line: 17, column: 19, scope: !23)
// CHECK:STDOUT: !25 = !DILocation(line: 17, column: 3, scope: !23)
// CHECK:STDOUT: !26 = !DILocation(line: 16, column: 1, scope: !23)
// CHECK:STDOUT: !27 = distinct !DISubprogram(name: "PassValueExpr", linkageName: "_CPassValueExpr.Main", scope: null, file: !1, line: 20, type: !28, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !31)
// CHECK:STDOUT: !28 = !DISubroutineType(types: !29)
// CHECK:STDOUT: !29 = !{null, !30}
// CHECK:STDOUT: !30 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !31 = !{!32}
// CHECK:STDOUT: !32 = !DILocalVariable(arg: 1, scope: !27, type: !30)
// CHECK:STDOUT: !33 = !DILocation(line: 21, column: 3, scope: !27)
// CHECK:STDOUT: !34 = !DILocation(line: 20, column: 1, scope: !27)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "PassRefExpr", linkageName: "_CPassRefExpr.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{null}
// CHECK:STDOUT: !15 = !DILocation(line: 7, column: 3, scope: !12)
// CHECK:STDOUT: !16 = !DILocation(line: 8, column: 3, scope: !12)
// CHECK:STDOUT: !17 = !DILocation(line: 9, column: 3, scope: !12)
// CHECK:STDOUT: !18 = !DILocation(line: 10, column: 3, scope: !12)
// CHECK:STDOUT: !19 = !DILocation(line: 11, column: 3, scope: !12)
// CHECK:STDOUT: !20 = !DILocation(line: 6, column: 1, scope: !12)
// CHECK:STDOUT: !21 = !{!22, !22, i64 0}
// CHECK:STDOUT: !22 = !{!"p1 _ZTS1Y", !23, i64 0}
// CHECK:STDOUT: !23 = !{!"any pointer", !10, i64 0}
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "PassInitExpr", linkageName: "_CPassInitExpr.Main", scope: null, file: !1, line: 16, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !25 = !DILocation(line: 17, column: 19, scope: !24)
// CHECK:STDOUT: !26 = !DILocation(line: 17, column: 3, scope: !24)
// CHECK:STDOUT: !27 = !DILocation(line: 16, column: 1, scope: !24)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "PassValueExpr", linkageName: "_CPassValueExpr.Main", scope: null, file: !1, line: 20, type: !29, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !32)
// CHECK:STDOUT: !29 = !DISubroutineType(types: !30)
// CHECK:STDOUT: !30 = !{null, !31}
// CHECK:STDOUT: !31 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !32 = !{!33}
// CHECK:STDOUT: !33 = !DILocalVariable(arg: 1, scope: !28, type: !31)
// CHECK:STDOUT: !34 = !DILocation(line: 21, column: 3, scope: !28)
// CHECK:STDOUT: !35 = !DILocation(line: 20, column: 1, scope: !28)
// CHECK:STDOUT:
@@ -119,121 +119,121 @@ fn Call(x: Cpp.D) -> Cpp.C {
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i8 @_CGetU8.Main() #0 !dbg !11 {
// CHECK:STDOUT: define i8 @_CGetU8.Main() #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc6_40.1.temp = alloca i8, align 1, !dbg !15
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc6_40.1.temp), !dbg !15
// CHECK:STDOUT: call void @_Z8ReturnU8v.carbon_thunk.(ptr %.loc6_40.1.temp), !dbg !15
// CHECK:STDOUT: %0 = load i8, ptr %.loc6_40.1.temp, align 1, !dbg !16
// CHECK:STDOUT: ret i8 %0, !dbg !16
// CHECK:STDOUT: %.loc6_40.1.temp = alloca i8, align 1, !dbg !16
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc6_40.1.temp), !dbg !16
// CHECK:STDOUT: call void @_Z8ReturnU8v.carbon_thunk.(ptr %.loc6_40.1.temp), !dbg !16
// CHECK:STDOUT: %0 = load i8, ptr %.loc6_40.1.temp, align 1, !dbg !17
// CHECK:STDOUT: ret i8 %0, !dbg !17
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
// CHECK:STDOUT: define internal void @_Z8ReturnU8v.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 !17
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !17
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !18
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !18
// CHECK:STDOUT: %call = call noundef zeroext i8 @_Z8ReturnU8v()
// CHECK:STDOUT: store i8 %call, ptr %0, align 1, !tbaa !20
// CHECK:STDOUT: store i8 %call, ptr %0, align 1, !tbaa !21
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i16 @_CGetU16.Main() #0 !dbg !21 {
// CHECK:STDOUT: define i16 @_CGetU16.Main() #0 !dbg !22 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc7_43.1.temp = alloca i16, align 2, !dbg !25
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_43.1.temp), !dbg !25
// CHECK:STDOUT: call void @_Z9ReturnU16v.carbon_thunk.(ptr %.loc7_43.1.temp), !dbg !25
// CHECK:STDOUT: %0 = load i16, ptr %.loc7_43.1.temp, align 2, !dbg !26
// CHECK:STDOUT: ret i16 %0, !dbg !26
// CHECK:STDOUT: %.loc7_43.1.temp = alloca i16, align 2, !dbg !26
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_43.1.temp), !dbg !26
// CHECK:STDOUT: call void @_Z9ReturnU16v.carbon_thunk.(ptr %.loc7_43.1.temp), !dbg !26
// CHECK:STDOUT: %0 = load i16, ptr %.loc7_43.1.temp, align 2, !dbg !27
// CHECK:STDOUT: ret i16 %0, !dbg !27
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
// CHECK:STDOUT: define internal void @_Z9ReturnU16v.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 !27
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !27
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !28
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !28
// CHECK:STDOUT: %call = call noundef zeroext i16 @_Z9ReturnU16v()
// CHECK:STDOUT: store i16 %call, ptr %0, align 2, !tbaa !29
// CHECK:STDOUT: store i16 %call, ptr %0, align 2, !tbaa !30
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i32 @_CGetU32.Main() #0 !dbg !31 {
// CHECK:STDOUT: define i32 @_CGetU32.Main() #0 !dbg !32 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %ReturnU32.call = call i32 @_Z9ReturnU32v(), !dbg !35
// CHECK:STDOUT: ret i32 %ReturnU32.call, !dbg !36
// CHECK:STDOUT: %ReturnU32.call = call i32 @_Z9ReturnU32v(), !dbg !36
// CHECK:STDOUT: ret i32 %ReturnU32.call, !dbg !37
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare noundef i32 @_Z9ReturnU32v() #2
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i64 @_CGetU64.Main() #0 !dbg !37 {
// CHECK:STDOUT: define i64 @_CGetU64.Main() #0 !dbg !38 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %ReturnU64.call = call i64 @_Z9ReturnU64v(), !dbg !41
// CHECK:STDOUT: ret i64 %ReturnU64.call, !dbg !42
// CHECK:STDOUT: %ReturnU64.call = call i64 @_Z9ReturnU64v(), !dbg !42
// CHECK:STDOUT: ret i64 %ReturnU64.call, !dbg !43
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare noundef i64 @_Z9ReturnU64v() #2
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i8 @_CGetI8.Main() #0 !dbg !43 {
// CHECK:STDOUT: define i8 @_CGetI8.Main() #0 !dbg !44 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc11_40.1.temp = alloca i8, align 1, !dbg !47
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc11_40.1.temp), !dbg !47
// CHECK:STDOUT: call void @_Z8ReturnI8v.carbon_thunk.(ptr %.loc11_40.1.temp), !dbg !47
// CHECK:STDOUT: %0 = load i8, ptr %.loc11_40.1.temp, align 1, !dbg !48
// CHECK:STDOUT: ret i8 %0, !dbg !48
// CHECK:STDOUT: %.loc11_40.1.temp = alloca i8, align 1, !dbg !48
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc11_40.1.temp), !dbg !48
// CHECK:STDOUT: call void @_Z8ReturnI8v.carbon_thunk.(ptr %.loc11_40.1.temp), !dbg !48
// CHECK:STDOUT: %0 = load i8, ptr %.loc11_40.1.temp, align 1, !dbg !49
// CHECK:STDOUT: ret i8 %0, !dbg !49
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
// CHECK:STDOUT: define internal void @_Z8ReturnI8v.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 !17
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !17
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !18
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !18
// CHECK:STDOUT: %call = call noundef signext i8 @_Z8ReturnI8v()
// CHECK:STDOUT: store i8 %call, ptr %0, align 1, !tbaa !20
// CHECK:STDOUT: store i8 %call, ptr %0, align 1, !tbaa !21
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i16 @_CGetI16.Main() #0 !dbg !49 {
// CHECK:STDOUT: define i16 @_CGetI16.Main() #0 !dbg !50 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc12_43.1.temp = alloca i16, align 2, !dbg !53
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc12_43.1.temp), !dbg !53
// CHECK:STDOUT: call void @_Z9ReturnI16v.carbon_thunk.(ptr %.loc12_43.1.temp), !dbg !53
// CHECK:STDOUT: %0 = load i16, ptr %.loc12_43.1.temp, align 2, !dbg !54
// CHECK:STDOUT: ret i16 %0, !dbg !54
// CHECK:STDOUT: %.loc12_43.1.temp = alloca i16, align 2, !dbg !54
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc12_43.1.temp), !dbg !54
// CHECK:STDOUT: call void @_Z9ReturnI16v.carbon_thunk.(ptr %.loc12_43.1.temp), !dbg !54
// CHECK:STDOUT: %0 = load i16, ptr %.loc12_43.1.temp, align 2, !dbg !55
// CHECK:STDOUT: ret i16 %0, !dbg !55
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
// CHECK:STDOUT: define internal void @_Z9ReturnI16v.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 !27
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !27
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !28
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !28
// CHECK:STDOUT: %call = call noundef signext i16 @_Z9ReturnI16v()
// CHECK:STDOUT: store i16 %call, ptr %0, align 2, !tbaa !29
// CHECK:STDOUT: store i16 %call, ptr %0, align 2, !tbaa !30
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i32 @_CGetI32.Main() #0 !dbg !55 {
// CHECK:STDOUT: define i32 @_CGetI32.Main() #0 !dbg !56 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %ReturnI32.call = call i32 @_Z9ReturnI32v(), !dbg !59
// CHECK:STDOUT: ret i32 %ReturnI32.call, !dbg !60
// CHECK:STDOUT: %ReturnI32.call = call i32 @_Z9ReturnI32v(), !dbg !60
// CHECK:STDOUT: ret i32 %ReturnI32.call, !dbg !61
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare noundef i32 @_Z9ReturnI32v() #2
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define i64 @_CGetI64.Main() #0 !dbg !61 {
// CHECK:STDOUT: define i64 @_CGetI64.Main() #0 !dbg !62 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %ReturnI64.call = call i64 @_Z9ReturnI64v(), !dbg !65
// CHECK:STDOUT: ret i64 %ReturnI64.call, !dbg !66
// CHECK:STDOUT: %ReturnI64.call = call i64 @_Z9ReturnI64v(), !dbg !66
// CHECK:STDOUT: ret i64 %ReturnI64.call, !dbg !67
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare noundef i64 @_Z9ReturnI64v() #2
@@ -241,133 +241,133 @@ fn Call(x: Cpp.D) -> Cpp.C {
// CHECK:STDOUT: declare void @_CUse.Main(i8, i16, i32, i64, i8, i16, i32, i64)
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CLets.Main() #0 !dbg !67 {
// CHECK:STDOUT: define void @_CLets.Main() #0 !dbg !68 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc19_32.1.temp = alloca i8, align 1, !dbg !70
// CHECK:STDOUT: %.loc20_35.1.temp = alloca i16, align 2, !dbg !71
// CHECK:STDOUT: %.loc24_32.1.temp = alloca i8, align 1, !dbg !72
// CHECK:STDOUT: %.loc25_35.1.temp = alloca i16, align 2, !dbg !73
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc19_32.1.temp), !dbg !70
// CHECK:STDOUT: call void @_Z8ReturnU8v.carbon_thunk.(ptr %.loc19_32.1.temp), !dbg !70
// CHECK:STDOUT: %.loc19_32.4 = load i8, ptr %.loc19_32.1.temp, align 1, !dbg !70
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_35.1.temp), !dbg !71
// CHECK:STDOUT: call void @_Z9ReturnU16v.carbon_thunk.(ptr %.loc20_35.1.temp), !dbg !71
// CHECK:STDOUT: %.loc20_35.4 = load i16, ptr %.loc20_35.1.temp, align 2, !dbg !71
// CHECK:STDOUT: %ReturnU32.call = call i32 @_Z9ReturnU32v(), !dbg !74
// CHECK:STDOUT: %ReturnU64.call = call i64 @_Z9ReturnU64v(), !dbg !75
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc24_32.1.temp), !dbg !72
// CHECK:STDOUT: call void @_Z8ReturnI8v.carbon_thunk.(ptr %.loc24_32.1.temp), !dbg !72
// CHECK:STDOUT: %.loc24_32.4 = load i8, ptr %.loc24_32.1.temp, align 1, !dbg !72
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc25_35.1.temp), !dbg !73
// CHECK:STDOUT: call void @_Z9ReturnI16v.carbon_thunk.(ptr %.loc25_35.1.temp), !dbg !73
// CHECK:STDOUT: %.loc25_35.4 = load i16, ptr %.loc25_35.1.temp, align 2, !dbg !73
// CHECK:STDOUT: %ReturnI32.call = call i32 @_Z9ReturnI32v(), !dbg !76
// CHECK:STDOUT: %ReturnI64.call = call i64 @_Z9ReturnI64v(), !dbg !77
// CHECK:STDOUT: call void @_CUse.Main(i8 %.loc19_32.4, i16 %.loc20_35.4, i32 %ReturnU32.call, i64 %ReturnU64.call, i8 %.loc24_32.4, i16 %.loc25_35.4, i32 %ReturnI32.call, i64 %ReturnI64.call), !dbg !78
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc25_35.1.temp), !dbg !73
// CHECK:STDOUT: call void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr %.loc24_32.1.temp), !dbg !72
// CHECK:STDOUT: call void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr %.loc20_35.1.temp), !dbg !71
// CHECK:STDOUT: call void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr %.loc19_32.1.temp), !dbg !70
// CHECK:STDOUT: ret void, !dbg !79
// CHECK:STDOUT: %.loc19_32.1.temp = alloca i8, align 1, !dbg !71
// CHECK:STDOUT: %.loc20_35.1.temp = alloca i16, align 2, !dbg !72
// CHECK:STDOUT: %.loc24_32.1.temp = alloca i8, align 1, !dbg !73
// CHECK:STDOUT: %.loc25_35.1.temp = alloca i16, align 2, !dbg !74
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc19_32.1.temp), !dbg !71
// CHECK:STDOUT: call void @_Z8ReturnU8v.carbon_thunk.(ptr %.loc19_32.1.temp), !dbg !71
// CHECK:STDOUT: %.loc19_32.4 = load i8, ptr %.loc19_32.1.temp, align 1, !dbg !71
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_35.1.temp), !dbg !72
// CHECK:STDOUT: call void @_Z9ReturnU16v.carbon_thunk.(ptr %.loc20_35.1.temp), !dbg !72
// CHECK:STDOUT: %.loc20_35.4 = load i16, ptr %.loc20_35.1.temp, align 2, !dbg !72
// CHECK:STDOUT: %ReturnU32.call = call i32 @_Z9ReturnU32v(), !dbg !75
// CHECK:STDOUT: %ReturnU64.call = call i64 @_Z9ReturnU64v(), !dbg !76
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc24_32.1.temp), !dbg !73
// CHECK:STDOUT: call void @_Z8ReturnI8v.carbon_thunk.(ptr %.loc24_32.1.temp), !dbg !73
// CHECK:STDOUT: %.loc24_32.4 = load i8, ptr %.loc24_32.1.temp, align 1, !dbg !73
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc25_35.1.temp), !dbg !74
// CHECK:STDOUT: call void @_Z9ReturnI16v.carbon_thunk.(ptr %.loc25_35.1.temp), !dbg !74
// CHECK:STDOUT: %.loc25_35.4 = load i16, ptr %.loc25_35.1.temp, align 2, !dbg !74
// CHECK:STDOUT: %ReturnI32.call = call i32 @_Z9ReturnI32v(), !dbg !77
// CHECK:STDOUT: %ReturnI64.call = call i64 @_Z9ReturnI64v(), !dbg !78
// CHECK:STDOUT: call void @_CUse.Main(i8 %.loc19_32.4, i16 %.loc20_35.4, i32 %ReturnU32.call, i64 %ReturnU64.call, i8 %.loc24_32.4, i16 %.loc25_35.4, i32 %ReturnI32.call, i64 %ReturnI64.call), !dbg !79
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %.loc25_35.1.temp), !dbg !74
// CHECK:STDOUT: call void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr %.loc24_32.1.temp), !dbg !73
// CHECK:STDOUT: call void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr %.loc20_35.1.temp), !dbg !72
// CHECK:STDOUT: call void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr %.loc19_32.1.temp), !dbg !71
// CHECK:STDOUT: ret void, !dbg !80
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %self) #0 !dbg !80 {
// CHECK:STDOUT: define weak_odr void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %self) #0 !dbg !81 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !85
// CHECK:STDOUT: ret void, !dbg !86
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr %self) #0 !dbg !86 {
// CHECK:STDOUT: define weak_odr void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr %self) #0 !dbg !87 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !91
// CHECK:STDOUT: ret void, !dbg !92
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr %self) #0 !dbg !92 {
// CHECK:STDOUT: define weak_odr void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr %self) #0 !dbg !93 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !97
// CHECK:STDOUT: ret void, !dbg !98
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr %self) #0 !dbg !98 {
// CHECK:STDOUT: define weak_odr void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr %self) #0 !dbg !99 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !103
// CHECK:STDOUT: ret void, !dbg !104
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CVars.Main() #0 !dbg !104 {
// CHECK:STDOUT: define void @_CVars.Main() #0 !dbg !105 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %my_u8.var = alloca i8, align 1, !dbg !105
// CHECK:STDOUT: %my_u16.var = alloca i16, align 2, !dbg !106
// CHECK:STDOUT: %my_u32.var = alloca i32, align 4, !dbg !107
// CHECK:STDOUT: %my_u64.var = alloca i64, align 8, !dbg !108
// CHECK:STDOUT: %my_i8.var = alloca i8, align 1, !dbg !109
// CHECK:STDOUT: %my_i16.var = alloca i16, align 2, !dbg !110
// CHECK:STDOUT: %my_i32.var = alloca i32, align 4, !dbg !111
// CHECK:STDOUT: %my_i64.var = alloca i64, align 8, !dbg !112
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_u8.var), !dbg !105
// CHECK:STDOUT: call void @_Z8ReturnU8v.carbon_thunk.(ptr %my_u8.var), !dbg !113
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_u16.var), !dbg !106
// CHECK:STDOUT: call void @_Z9ReturnU16v.carbon_thunk.(ptr %my_u16.var), !dbg !114
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_u32.var), !dbg !107
// CHECK:STDOUT: %ReturnU32.call = call i32 @_Z9ReturnU32v(), !dbg !115
// CHECK:STDOUT: store i32 %ReturnU32.call, ptr %my_u32.var, align 4, !dbg !107
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_u64.var), !dbg !108
// CHECK:STDOUT: %ReturnU64.call = call i64 @_Z9ReturnU64v(), !dbg !116
// CHECK:STDOUT: store i64 %ReturnU64.call, ptr %my_u64.var, align 8, !dbg !108
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_i8.var), !dbg !109
// CHECK:STDOUT: call void @_Z8ReturnI8v.carbon_thunk.(ptr %my_i8.var), !dbg !117
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_i16.var), !dbg !110
// CHECK:STDOUT: call void @_Z9ReturnI16v.carbon_thunk.(ptr %my_i16.var), !dbg !118
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_i32.var), !dbg !111
// CHECK:STDOUT: %ReturnI32.call = call i32 @_Z9ReturnI32v(), !dbg !119
// CHECK:STDOUT: store i32 %ReturnI32.call, ptr %my_i32.var, align 4, !dbg !111
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_i64.var), !dbg !112
// CHECK:STDOUT: %ReturnI64.call = call i64 @_Z9ReturnI64v(), !dbg !120
// CHECK:STDOUT: store i64 %ReturnI64.call, ptr %my_i64.var, align 8, !dbg !112
// CHECK:STDOUT: %.loc43_7 = load i8, ptr %my_u8.var, align 1, !dbg !121
// CHECK:STDOUT: %.loc43_14 = load i16, ptr %my_u16.var, align 2, !dbg !122
// CHECK:STDOUT: %.loc43_22 = load i32, ptr %my_u32.var, align 4, !dbg !123
// CHECK:STDOUT: %.loc43_30 = load i64, ptr %my_u64.var, align 8, !dbg !124
// CHECK:STDOUT: %.loc43_38 = load i8, ptr %my_i8.var, align 1, !dbg !125
// CHECK:STDOUT: %.loc43_45 = load i16, ptr %my_i16.var, align 2, !dbg !126
// CHECK:STDOUT: %.loc43_53 = load i32, ptr %my_i32.var, align 4, !dbg !127
// CHECK:STDOUT: %.loc43_61 = load i64, ptr %my_i64.var, align 8, !dbg !128
// CHECK:STDOUT: call void @_CUse.Main(i8 %.loc43_7, i16 %.loc43_14, i32 %.loc43_22, i64 %.loc43_30, i8 %.loc43_38, i16 %.loc43_45, i32 %.loc43_53, i64 %.loc43_61), !dbg !129
// CHECK:STDOUT: call void @"_COp.fbec46972c1998a0:core.Destroy.Core"(ptr %my_i64.var), !dbg !112
// CHECK:STDOUT: call void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %my_i32.var), !dbg !111
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %my_i16.var), !dbg !110
// CHECK:STDOUT: call void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr %my_i8.var), !dbg !109
// CHECK:STDOUT: call void @"_COp.df57f49075d1fe6b:core.Destroy.Core"(ptr %my_u64.var), !dbg !108
// CHECK:STDOUT: call void @"_COp.45ecfb19e8cc5ab3:core.Destroy.Core"(ptr %my_u32.var), !dbg !107
// CHECK:STDOUT: call void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr %my_u16.var), !dbg !106
// CHECK:STDOUT: call void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr %my_u8.var), !dbg !105
// CHECK:STDOUT: ret void, !dbg !130
// CHECK:STDOUT: %my_u8.var = alloca i8, align 1, !dbg !106
// CHECK:STDOUT: %my_u16.var = alloca i16, align 2, !dbg !107
// CHECK:STDOUT: %my_u32.var = alloca i32, align 4, !dbg !108
// CHECK:STDOUT: %my_u64.var = alloca i64, align 8, !dbg !109
// CHECK:STDOUT: %my_i8.var = alloca i8, align 1, !dbg !110
// CHECK:STDOUT: %my_i16.var = alloca i16, align 2, !dbg !111
// CHECK:STDOUT: %my_i32.var = alloca i32, align 4, !dbg !112
// CHECK:STDOUT: %my_i64.var = alloca i64, align 8, !dbg !113
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_u8.var), !dbg !106
// CHECK:STDOUT: call void @_Z8ReturnU8v.carbon_thunk.(ptr %my_u8.var), !dbg !114
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_u16.var), !dbg !107
// CHECK:STDOUT: call void @_Z9ReturnU16v.carbon_thunk.(ptr %my_u16.var), !dbg !115
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_u32.var), !dbg !108
// CHECK:STDOUT: %ReturnU32.call = call i32 @_Z9ReturnU32v(), !dbg !116
// CHECK:STDOUT: store i32 %ReturnU32.call, ptr %my_u32.var, align 4, !dbg !108
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_u64.var), !dbg !109
// CHECK:STDOUT: %ReturnU64.call = call i64 @_Z9ReturnU64v(), !dbg !117
// CHECK:STDOUT: store i64 %ReturnU64.call, ptr %my_u64.var, align 8, !dbg !109
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_i8.var), !dbg !110
// CHECK:STDOUT: call void @_Z8ReturnI8v.carbon_thunk.(ptr %my_i8.var), !dbg !118
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_i16.var), !dbg !111
// CHECK:STDOUT: call void @_Z9ReturnI16v.carbon_thunk.(ptr %my_i16.var), !dbg !119
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_i32.var), !dbg !112
// CHECK:STDOUT: %ReturnI32.call = call i32 @_Z9ReturnI32v(), !dbg !120
// CHECK:STDOUT: store i32 %ReturnI32.call, ptr %my_i32.var, align 4, !dbg !112
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %my_i64.var), !dbg !113
// CHECK:STDOUT: %ReturnI64.call = call i64 @_Z9ReturnI64v(), !dbg !121
// CHECK:STDOUT: store i64 %ReturnI64.call, ptr %my_i64.var, align 8, !dbg !113
// CHECK:STDOUT: %.loc43_7 = load i8, ptr %my_u8.var, align 1, !dbg !122
// CHECK:STDOUT: %.loc43_14 = load i16, ptr %my_u16.var, align 2, !dbg !123
// CHECK:STDOUT: %.loc43_22 = load i32, ptr %my_u32.var, align 4, !dbg !124
// CHECK:STDOUT: %.loc43_30 = load i64, ptr %my_u64.var, align 8, !dbg !125
// CHECK:STDOUT: %.loc43_38 = load i8, ptr %my_i8.var, align 1, !dbg !126
// CHECK:STDOUT: %.loc43_45 = load i16, ptr %my_i16.var, align 2, !dbg !127
// CHECK:STDOUT: %.loc43_53 = load i32, ptr %my_i32.var, align 4, !dbg !128
// CHECK:STDOUT: %.loc43_61 = load i64, ptr %my_i64.var, align 8, !dbg !129
// CHECK:STDOUT: call void @_CUse.Main(i8 %.loc43_7, i16 %.loc43_14, i32 %.loc43_22, i64 %.loc43_30, i8 %.loc43_38, i16 %.loc43_45, i32 %.loc43_53, i64 %.loc43_61), !dbg !130
// CHECK:STDOUT: call void @"_COp.fbec46972c1998a0:core.Destroy.Core"(ptr %my_i64.var), !dbg !113
// CHECK:STDOUT: call void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %my_i32.var), !dbg !112
// CHECK:STDOUT: call void @"_COp.eb6702152d47e49f:core.Destroy.Core"(ptr %my_i16.var), !dbg !111
// CHECK:STDOUT: call void @"_COp.578b3934f85dbca6:core.Destroy.Core"(ptr %my_i8.var), !dbg !110
// CHECK:STDOUT: call void @"_COp.df57f49075d1fe6b:core.Destroy.Core"(ptr %my_u64.var), !dbg !109
// CHECK:STDOUT: call void @"_COp.45ecfb19e8cc5ab3:core.Destroy.Core"(ptr %my_u32.var), !dbg !108
// CHECK:STDOUT: call void @"_COp.6fd0ed7da7a22bb4:core.Destroy.Core"(ptr %my_u16.var), !dbg !107
// CHECK:STDOUT: call void @"_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core"(ptr %my_u8.var), !dbg !106
// CHECK:STDOUT: ret void, !dbg !131
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.fbec46972c1998a0:core.Destroy.Core"(ptr %self) #0 !dbg !131 {
// CHECK:STDOUT: define weak_odr void @"_COp.fbec46972c1998a0:core.Destroy.Core"(ptr %self) #0 !dbg !132 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !136
// CHECK:STDOUT: ret void, !dbg !137
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %self) #0 !dbg !137 {
// CHECK:STDOUT: define weak_odr void @"_COp.5e27612b9dd31a14:core.Destroy.Core"(ptr %self) #0 !dbg !138 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !142
// CHECK:STDOUT: ret void, !dbg !143
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.df57f49075d1fe6b:core.Destroy.Core"(ptr %self) #0 !dbg !143 {
// CHECK:STDOUT: define weak_odr void @"_COp.df57f49075d1fe6b:core.Destroy.Core"(ptr %self) #0 !dbg !144 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !148
// CHECK:STDOUT: ret void, !dbg !149
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.45ecfb19e8cc5ab3:core.Destroy.Core"(ptr %self) #0 !dbg !149 {
// CHECK:STDOUT: define weak_odr void @"_COp.45ecfb19e8cc5ab3:core.Destroy.Core"(ptr %self) #0 !dbg !150 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !154
// CHECK:STDOUT: ret void, !dbg !155
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
@@ -400,154 +400,155 @@ fn Call(x: Cpp.D) -> Cpp.C {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "GetU8", linkageName: "_CGetU8.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{!14}
// CHECK:STDOUT: !14 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !15 = !DILocation(line: 6, column: 27, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 20, scope: !11)
// CHECK:STDOUT: !17 = !{!18, !18, i64 0}
// CHECK:STDOUT: !18 = !{!"p1 omnipotent char", !19, i64 0}
// CHECK:STDOUT: !19 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !20 = !{!9, !9, i64 0}
// CHECK:STDOUT: !21 = distinct !DISubprogram(name: "GetU16", linkageName: "_CGetU16.Main", scope: null, file: !1, line: 7, type: !22, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !22 = !DISubroutineType(types: !23)
// CHECK:STDOUT: !23 = !{!24}
// CHECK:STDOUT: !24 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !25 = !DILocation(line: 7, column: 29, scope: !21)
// CHECK:STDOUT: !26 = !DILocation(line: 7, column: 22, scope: !21)
// CHECK:STDOUT: !27 = !{!28, !28, i64 0}
// CHECK:STDOUT: !28 = !{!"p1 short", !19, i64 0}
// CHECK:STDOUT: !29 = !{!30, !30, i64 0}
// CHECK:STDOUT: !30 = !{!"short", !9, i64 0}
// CHECK:STDOUT: !31 = distinct !DISubprogram(name: "GetU32", linkageName: "_CGetU32.Main", scope: null, file: !1, line: 8, type: !32, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !32 = !DISubroutineType(types: !33)
// CHECK:STDOUT: !33 = !{!34}
// CHECK:STDOUT: !34 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !35 = !DILocation(line: 8, column: 29, scope: !31)
// CHECK:STDOUT: !36 = !DILocation(line: 8, column: 22, scope: !31)
// CHECK:STDOUT: !37 = distinct !DISubprogram(name: "GetU64", linkageName: "_CGetU64.Main", scope: null, file: !1, line: 9, type: !38, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !38 = !DISubroutineType(types: !39)
// CHECK:STDOUT: !39 = !{!40}
// CHECK:STDOUT: !40 = !DIBasicType(name: "int", size: 64, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !41 = !DILocation(line: 9, column: 29, scope: !37)
// CHECK:STDOUT: !42 = !DILocation(line: 9, column: 22, scope: !37)
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "GetI8", linkageName: "_CGetI8.Main", scope: null, file: !1, line: 11, type: !44, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !44 = !DISubroutineType(types: !45)
// CHECK:STDOUT: !45 = !{!46}
// CHECK:STDOUT: !46 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_signed)
// CHECK:STDOUT: !47 = !DILocation(line: 11, column: 27, scope: !43)
// CHECK:STDOUT: !48 = !DILocation(line: 11, column: 20, scope: !43)
// CHECK:STDOUT: !49 = distinct !DISubprogram(name: "GetI16", linkageName: "_CGetI16.Main", scope: null, file: !1, line: 12, type: !50, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !50 = !DISubroutineType(types: !51)
// CHECK:STDOUT: !51 = !{!52}
// CHECK:STDOUT: !52 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_signed)
// CHECK:STDOUT: !53 = !DILocation(line: 12, column: 29, scope: !49)
// CHECK:STDOUT: !54 = !DILocation(line: 12, column: 22, scope: !49)
// CHECK:STDOUT: !55 = distinct !DISubprogram(name: "GetI32", linkageName: "_CGetI32.Main", scope: null, file: !1, line: 13, type: !56, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !56 = !DISubroutineType(types: !57)
// CHECK:STDOUT: !57 = !{!58}
// CHECK:STDOUT: !58 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !59 = !DILocation(line: 13, column: 29, scope: !55)
// CHECK:STDOUT: !60 = !DILocation(line: 13, column: 22, scope: !55)
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "GetI64", linkageName: "_CGetI64.Main", scope: null, file: !1, line: 14, type: !62, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !62 = !DISubroutineType(types: !63)
// CHECK:STDOUT: !63 = !{!64}
// CHECK:STDOUT: !64 = !DIBasicType(name: "int", size: 64, encoding: DW_ATE_signed)
// CHECK:STDOUT: !65 = !DILocation(line: 14, column: 29, scope: !61)
// CHECK:STDOUT: !66 = !DILocation(line: 14, column: 22, scope: !61)
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "Lets", linkageName: "_CLets.Main", scope: null, file: !1, line: 18, type: !68, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !68 = !DISubroutineType(types: !69)
// CHECK:STDOUT: !69 = !{null}
// CHECK:STDOUT: !70 = !DILocation(line: 19, column: 19, scope: !67)
// CHECK:STDOUT: !71 = !DILocation(line: 20, column: 21, scope: !67)
// CHECK:STDOUT: !72 = !DILocation(line: 24, column: 19, scope: !67)
// CHECK:STDOUT: !73 = !DILocation(line: 25, column: 21, scope: !67)
// CHECK:STDOUT: !74 = !DILocation(line: 21, column: 21, scope: !67)
// CHECK:STDOUT: !75 = !DILocation(line: 22, column: 21, scope: !67)
// CHECK:STDOUT: !76 = !DILocation(line: 26, column: 21, scope: !67)
// CHECK:STDOUT: !77 = !DILocation(line: 27, column: 21, scope: !67)
// CHECK:STDOUT: !78 = !DILocation(line: 29, column: 3, scope: !67)
// CHECK:STDOUT: !79 = !DILocation(line: 18, column: 1, scope: !67)
// CHECK:STDOUT: !80 = distinct !DISubprogram(name: "Op", linkageName: "_COp.eb6702152d47e49f:core.Destroy.Core", scope: null, file: !1, line: 25, type: !81, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !83)
// CHECK:STDOUT: !81 = !DISubroutineType(types: !82)
// CHECK:STDOUT: !82 = !{null, !52}
// CHECK:STDOUT: !83 = !{!84}
// CHECK:STDOUT: !84 = !DILocalVariable(arg: 1, scope: !80, type: !52)
// CHECK:STDOUT: !85 = !DILocation(line: 25, column: 21, scope: !80)
// CHECK:STDOUT: !86 = distinct !DISubprogram(name: "Op", linkageName: "_COp.578b3934f85dbca6:core.Destroy.Core", scope: null, file: !1, line: 24, type: !87, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !89)
// CHECK:STDOUT: !87 = !DISubroutineType(types: !88)
// CHECK:STDOUT: !88 = !{null, !46}
// CHECK:STDOUT: !89 = !{!90}
// CHECK:STDOUT: !90 = !DILocalVariable(arg: 1, scope: !86, type: !46)
// CHECK:STDOUT: !91 = !DILocation(line: 24, column: 19, scope: !86)
// CHECK:STDOUT: !92 = distinct !DISubprogram(name: "Op", linkageName: "_COp.6fd0ed7da7a22bb4:core.Destroy.Core", scope: null, file: !1, line: 20, type: !93, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !95)
// CHECK:STDOUT: !93 = !DISubroutineType(types: !94)
// CHECK:STDOUT: !94 = !{null, !24}
// CHECK:STDOUT: !95 = !{!96}
// CHECK:STDOUT: !96 = !DILocalVariable(arg: 1, scope: !92, type: !24)
// CHECK:STDOUT: !97 = !DILocation(line: 20, column: 21, scope: !92)
// CHECK:STDOUT: !98 = distinct !DISubprogram(name: "Op", linkageName: "_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core", scope: null, file: !1, line: 19, type: !99, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !101)
// CHECK:STDOUT: !99 = !DISubroutineType(types: !100)
// CHECK:STDOUT: !100 = !{null, !14}
// CHECK:STDOUT: !101 = !{!102}
// CHECK:STDOUT: !102 = !DILocalVariable(arg: 1, scope: !98, type: !14)
// CHECK:STDOUT: !103 = !DILocation(line: 19, column: 19, scope: !98)
// CHECK:STDOUT: !104 = distinct !DISubprogram(name: "Vars", linkageName: "_CVars.Main", scope: null, file: !1, line: 32, type: !68, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !105 = !DILocation(line: 33, column: 3, scope: !104)
// CHECK:STDOUT: !106 = !DILocation(line: 34, column: 3, scope: !104)
// CHECK:STDOUT: !107 = !DILocation(line: 35, column: 3, scope: !104)
// CHECK:STDOUT: !108 = !DILocation(line: 36, column: 3, scope: !104)
// CHECK:STDOUT: !109 = !DILocation(line: 38, column: 3, scope: !104)
// CHECK:STDOUT: !110 = !DILocation(line: 39, column: 3, scope: !104)
// CHECK:STDOUT: !111 = !DILocation(line: 40, column: 3, scope: !104)
// CHECK:STDOUT: !112 = !DILocation(line: 41, column: 3, scope: !104)
// CHECK:STDOUT: !113 = !DILocation(line: 33, column: 19, scope: !104)
// CHECK:STDOUT: !114 = !DILocation(line: 34, column: 21, scope: !104)
// CHECK:STDOUT: !115 = !DILocation(line: 35, column: 21, scope: !104)
// CHECK:STDOUT: !116 = !DILocation(line: 36, column: 21, scope: !104)
// CHECK:STDOUT: !117 = !DILocation(line: 38, column: 19, scope: !104)
// CHECK:STDOUT: !118 = !DILocation(line: 39, column: 21, scope: !104)
// CHECK:STDOUT: !119 = !DILocation(line: 40, column: 21, scope: !104)
// CHECK:STDOUT: !120 = !DILocation(line: 41, column: 21, scope: !104)
// CHECK:STDOUT: !121 = !DILocation(line: 43, column: 7, scope: !104)
// CHECK:STDOUT: !122 = !DILocation(line: 43, column: 14, scope: !104)
// CHECK:STDOUT: !123 = !DILocation(line: 43, column: 22, scope: !104)
// CHECK:STDOUT: !124 = !DILocation(line: 43, column: 30, scope: !104)
// CHECK:STDOUT: !125 = !DILocation(line: 43, column: 38, scope: !104)
// CHECK:STDOUT: !126 = !DILocation(line: 43, column: 45, scope: !104)
// CHECK:STDOUT: !127 = !DILocation(line: 43, column: 53, scope: !104)
// CHECK:STDOUT: !128 = !DILocation(line: 43, column: 61, scope: !104)
// CHECK:STDOUT: !129 = !DILocation(line: 43, column: 3, scope: !104)
// CHECK:STDOUT: !130 = !DILocation(line: 32, column: 1, scope: !104)
// CHECK:STDOUT: !131 = distinct !DISubprogram(name: "Op", linkageName: "_COp.fbec46972c1998a0:core.Destroy.Core", scope: null, file: !1, line: 41, type: !132, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !134)
// CHECK:STDOUT: !132 = !DISubroutineType(types: !133)
// CHECK:STDOUT: !133 = !{null, !64}
// CHECK:STDOUT: !134 = !{!135}
// CHECK:STDOUT: !135 = !DILocalVariable(arg: 1, scope: !131, type: !64)
// CHECK:STDOUT: !136 = !DILocation(line: 41, column: 3, scope: !131)
// CHECK:STDOUT: !137 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5e27612b9dd31a14:core.Destroy.Core", scope: null, file: !1, line: 40, type: !138, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !140)
// CHECK:STDOUT: !138 = !DISubroutineType(types: !139)
// CHECK:STDOUT: !139 = !{null, !58}
// CHECK:STDOUT: !140 = !{!141}
// CHECK:STDOUT: !141 = !DILocalVariable(arg: 1, scope: !137, type: !58)
// CHECK:STDOUT: !142 = !DILocation(line: 40, column: 3, scope: !137)
// CHECK:STDOUT: !143 = distinct !DISubprogram(name: "Op", linkageName: "_COp.df57f49075d1fe6b:core.Destroy.Core", scope: null, file: !1, line: 36, type: !144, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !146)
// CHECK:STDOUT: !144 = !DISubroutineType(types: !145)
// CHECK:STDOUT: !145 = !{null, !40}
// CHECK:STDOUT: !146 = !{!147}
// CHECK:STDOUT: !147 = !DILocalVariable(arg: 1, scope: !143, type: !40)
// CHECK:STDOUT: !148 = !DILocation(line: 36, column: 3, scope: !143)
// CHECK:STDOUT: !149 = distinct !DISubprogram(name: "Op", linkageName: "_COp.45ecfb19e8cc5ab3:core.Destroy.Core", scope: null, file: !1, line: 35, type: !150, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !152)
// CHECK:STDOUT: !150 = !DISubroutineType(types: !151)
// CHECK:STDOUT: !151 = !{null, !34}
// CHECK:STDOUT: !152 = !{!153}
// CHECK:STDOUT: !153 = !DILocalVariable(arg: 1, scope: !149, type: !34)
// CHECK:STDOUT: !154 = !DILocation(line: 35, column: 3, scope: !149)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "GetU8", linkageName: "_CGetU8.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{!15}
// CHECK:STDOUT: !15 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 27, scope: !12)
// CHECK:STDOUT: !17 = !DILocation(line: 6, column: 20, scope: !12)
// CHECK:STDOUT: !18 = !{!19, !19, i64 0}
// CHECK:STDOUT: !19 = !{!"p1 omnipotent char", !20, i64 0}
// CHECK:STDOUT: !20 = !{!"any pointer", !10, i64 0}
// CHECK:STDOUT: !21 = !{!10, !10, i64 0}
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "GetU16", linkageName: "_CGetU16.Main", scope: null, file: !1, line: 7, type: !23, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !23 = !DISubroutineType(types: !24)
// CHECK:STDOUT: !24 = !{!25}
// CHECK:STDOUT: !25 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !26 = !DILocation(line: 7, column: 29, scope: !22)
// CHECK:STDOUT: !27 = !DILocation(line: 7, column: 22, scope: !22)
// CHECK:STDOUT: !28 = !{!29, !29, i64 0}
// CHECK:STDOUT: !29 = !{!"p1 short", !20, i64 0}
// CHECK:STDOUT: !30 = !{!31, !31, i64 0}
// CHECK:STDOUT: !31 = !{!"short", !10, i64 0}
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "GetU32", linkageName: "_CGetU32.Main", scope: null, file: !1, line: 8, type: !33, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !33 = !DISubroutineType(types: !34)
// CHECK:STDOUT: !34 = !{!35}
// CHECK:STDOUT: !35 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !36 = !DILocation(line: 8, column: 29, scope: !32)
// CHECK:STDOUT: !37 = !DILocation(line: 8, column: 22, scope: !32)
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "GetU64", linkageName: "_CGetU64.Main", scope: null, file: !1, line: 9, type: !39, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !39 = !DISubroutineType(types: !40)
// CHECK:STDOUT: !40 = !{!41}
// CHECK:STDOUT: !41 = !DIBasicType(name: "int", size: 64, encoding: DW_ATE_unsigned)
// CHECK:STDOUT: !42 = !DILocation(line: 9, column: 29, scope: !38)
// CHECK:STDOUT: !43 = !DILocation(line: 9, column: 22, scope: !38)
// CHECK:STDOUT: !44 = distinct !DISubprogram(name: "GetI8", linkageName: "_CGetI8.Main", scope: null, file: !1, line: 11, type: !45, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !45 = !DISubroutineType(types: !46)
// CHECK:STDOUT: !46 = !{!47}
// CHECK:STDOUT: !47 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_signed)
// CHECK:STDOUT: !48 = !DILocation(line: 11, column: 27, scope: !44)
// CHECK:STDOUT: !49 = !DILocation(line: 11, column: 20, scope: !44)
// CHECK:STDOUT: !50 = distinct !DISubprogram(name: "GetI16", linkageName: "_CGetI16.Main", scope: null, file: !1, line: 12, type: !51, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !51 = !DISubroutineType(types: !52)
// CHECK:STDOUT: !52 = !{!53}
// CHECK:STDOUT: !53 = !DIBasicType(name: "int", size: 16, encoding: DW_ATE_signed)
// CHECK:STDOUT: !54 = !DILocation(line: 12, column: 29, scope: !50)
// CHECK:STDOUT: !55 = !DILocation(line: 12, column: 22, scope: !50)
// CHECK:STDOUT: !56 = distinct !DISubprogram(name: "GetI32", linkageName: "_CGetI32.Main", scope: null, file: !1, line: 13, type: !57, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !57 = !DISubroutineType(types: !58)
// CHECK:STDOUT: !58 = !{!59}
// CHECK:STDOUT: !59 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !60 = !DILocation(line: 13, column: 29, scope: !56)
// CHECK:STDOUT: !61 = !DILocation(line: 13, column: 22, scope: !56)
// CHECK:STDOUT: !62 = distinct !DISubprogram(name: "GetI64", linkageName: "_CGetI64.Main", scope: null, file: !1, line: 14, type: !63, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !63 = !DISubroutineType(types: !64)
// CHECK:STDOUT: !64 = !{!65}
// CHECK:STDOUT: !65 = !DIBasicType(name: "int", size: 64, encoding: DW_ATE_signed)
// CHECK:STDOUT: !66 = !DILocation(line: 14, column: 29, scope: !62)
// CHECK:STDOUT: !67 = !DILocation(line: 14, column: 22, scope: !62)
// CHECK:STDOUT: !68 = distinct !DISubprogram(name: "Lets", linkageName: "_CLets.Main", scope: null, file: !1, line: 18, type: !69, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !69 = !DISubroutineType(types: !70)
// CHECK:STDOUT: !70 = !{null}
// CHECK:STDOUT: !71 = !DILocation(line: 19, column: 19, scope: !68)
// CHECK:STDOUT: !72 = !DILocation(line: 20, column: 21, scope: !68)
// CHECK:STDOUT: !73 = !DILocation(line: 24, column: 19, scope: !68)
// CHECK:STDOUT: !74 = !DILocation(line: 25, column: 21, scope: !68)
// CHECK:STDOUT: !75 = !DILocation(line: 21, column: 21, scope: !68)
// CHECK:STDOUT: !76 = !DILocation(line: 22, column: 21, scope: !68)
// CHECK:STDOUT: !77 = !DILocation(line: 26, column: 21, scope: !68)
// CHECK:STDOUT: !78 = !DILocation(line: 27, column: 21, scope: !68)
// CHECK:STDOUT: !79 = !DILocation(line: 29, column: 3, scope: !68)
// CHECK:STDOUT: !80 = !DILocation(line: 18, column: 1, scope: !68)
// CHECK:STDOUT: !81 = distinct !DISubprogram(name: "Op", linkageName: "_COp.eb6702152d47e49f:core.Destroy.Core", scope: null, file: !1, line: 25, type: !82, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !84)
// CHECK:STDOUT: !82 = !DISubroutineType(types: !83)
// CHECK:STDOUT: !83 = !{null, !53}
// CHECK:STDOUT: !84 = !{!85}
// CHECK:STDOUT: !85 = !DILocalVariable(arg: 1, scope: !81, type: !53)
// CHECK:STDOUT: !86 = !DILocation(line: 25, column: 21, scope: !81)
// CHECK:STDOUT: !87 = distinct !DISubprogram(name: "Op", linkageName: "_COp.578b3934f85dbca6:core.Destroy.Core", scope: null, file: !1, line: 24, type: !88, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !90)
// CHECK:STDOUT: !88 = !DISubroutineType(types: !89)
// CHECK:STDOUT: !89 = !{null, !47}
// CHECK:STDOUT: !90 = !{!91}
// CHECK:STDOUT: !91 = !DILocalVariable(arg: 1, scope: !87, type: !47)
// CHECK:STDOUT: !92 = !DILocation(line: 24, column: 19, scope: !87)
// CHECK:STDOUT: !93 = distinct !DISubprogram(name: "Op", linkageName: "_COp.6fd0ed7da7a22bb4:core.Destroy.Core", scope: null, file: !1, line: 20, type: !94, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !96)
// CHECK:STDOUT: !94 = !DISubroutineType(types: !95)
// CHECK:STDOUT: !95 = !{null, !25}
// CHECK:STDOUT: !96 = !{!97}
// CHECK:STDOUT: !97 = !DILocalVariable(arg: 1, scope: !93, type: !25)
// CHECK:STDOUT: !98 = !DILocation(line: 20, column: 21, scope: !93)
// CHECK:STDOUT: !99 = distinct !DISubprogram(name: "Op", linkageName: "_COp.c3b9dc9c7e0d5d3d:core.Destroy.Core", scope: null, file: !1, line: 19, type: !100, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !102)
// CHECK:STDOUT: !100 = !DISubroutineType(types: !101)
// CHECK:STDOUT: !101 = !{null, !15}
// CHECK:STDOUT: !102 = !{!103}
// CHECK:STDOUT: !103 = !DILocalVariable(arg: 1, scope: !99, type: !15)
// CHECK:STDOUT: !104 = !DILocation(line: 19, column: 19, scope: !99)
// CHECK:STDOUT: !105 = distinct !DISubprogram(name: "Vars", linkageName: "_CVars.Main", scope: null, file: !1, line: 32, type: !69, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !106 = !DILocation(line: 33, column: 3, scope: !105)
// CHECK:STDOUT: !107 = !DILocation(line: 34, column: 3, scope: !105)
// CHECK:STDOUT: !108 = !DILocation(line: 35, column: 3, scope: !105)
// CHECK:STDOUT: !109 = !DILocation(line: 36, column: 3, scope: !105)
// CHECK:STDOUT: !110 = !DILocation(line: 38, column: 3, scope: !105)
// CHECK:STDOUT: !111 = !DILocation(line: 39, column: 3, scope: !105)
// CHECK:STDOUT: !112 = !DILocation(line: 40, column: 3, scope: !105)
// CHECK:STDOUT: !113 = !DILocation(line: 41, column: 3, scope: !105)
// CHECK:STDOUT: !114 = !DILocation(line: 33, column: 19, scope: !105)
// CHECK:STDOUT: !115 = !DILocation(line: 34, column: 21, scope: !105)
// CHECK:STDOUT: !116 = !DILocation(line: 35, column: 21, scope: !105)
// CHECK:STDOUT: !117 = !DILocation(line: 36, column: 21, scope: !105)
// CHECK:STDOUT: !118 = !DILocation(line: 38, column: 19, scope: !105)
// CHECK:STDOUT: !119 = !DILocation(line: 39, column: 21, scope: !105)
// CHECK:STDOUT: !120 = !DILocation(line: 40, column: 21, scope: !105)
// CHECK:STDOUT: !121 = !DILocation(line: 41, column: 21, scope: !105)
// CHECK:STDOUT: !122 = !DILocation(line: 43, column: 7, scope: !105)
// CHECK:STDOUT: !123 = !DILocation(line: 43, column: 14, scope: !105)
// CHECK:STDOUT: !124 = !DILocation(line: 43, column: 22, scope: !105)
// CHECK:STDOUT: !125 = !DILocation(line: 43, column: 30, scope: !105)
// CHECK:STDOUT: !126 = !DILocation(line: 43, column: 38, scope: !105)
// CHECK:STDOUT: !127 = !DILocation(line: 43, column: 45, scope: !105)
// CHECK:STDOUT: !128 = !DILocation(line: 43, column: 53, scope: !105)
// CHECK:STDOUT: !129 = !DILocation(line: 43, column: 61, scope: !105)
// CHECK:STDOUT: !130 = !DILocation(line: 43, column: 3, scope: !105)
// CHECK:STDOUT: !131 = !DILocation(line: 32, column: 1, scope: !105)
// CHECK:STDOUT: !132 = distinct !DISubprogram(name: "Op", linkageName: "_COp.fbec46972c1998a0:core.Destroy.Core", scope: null, file: !1, line: 41, type: !133, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !135)
// CHECK:STDOUT: !133 = !DISubroutineType(types: !134)
// CHECK:STDOUT: !134 = !{null, !65}
// CHECK:STDOUT: !135 = !{!136}
// CHECK:STDOUT: !136 = !DILocalVariable(arg: 1, scope: !132, type: !65)
// CHECK:STDOUT: !137 = !DILocation(line: 41, column: 3, scope: !132)
// CHECK:STDOUT: !138 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5e27612b9dd31a14:core.Destroy.Core", scope: null, file: !1, line: 40, type: !139, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !141)
// CHECK:STDOUT: !139 = !DISubroutineType(types: !140)
// CHECK:STDOUT: !140 = !{null, !59}
// CHECK:STDOUT: !141 = !{!142}
// CHECK:STDOUT: !142 = !DILocalVariable(arg: 1, scope: !138, type: !59)
// CHECK:STDOUT: !143 = !DILocation(line: 40, column: 3, scope: !138)
// CHECK:STDOUT: !144 = distinct !DISubprogram(name: "Op", linkageName: "_COp.df57f49075d1fe6b:core.Destroy.Core", scope: null, file: !1, line: 36, type: !145, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !147)
// CHECK:STDOUT: !145 = !DISubroutineType(types: !146)
// CHECK:STDOUT: !146 = !{null, !41}
// CHECK:STDOUT: !147 = !{!148}
// CHECK:STDOUT: !148 = !DILocalVariable(arg: 1, scope: !144, type: !41)
// CHECK:STDOUT: !149 = !DILocation(line: 36, column: 3, scope: !144)
// CHECK:STDOUT: !150 = distinct !DISubprogram(name: "Op", linkageName: "_COp.45ecfb19e8cc5ab3:core.Destroy.Core", scope: null, file: !1, line: 35, type: !151, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !153)
// CHECK:STDOUT: !151 = !DISubroutineType(types: !152)
// CHECK:STDOUT: !152 = !{null, !35}
// CHECK:STDOUT: !153 = !{!154}
// CHECK:STDOUT: !154 = !DILocalVariable(arg: 1, scope: !150, type: !35)
// CHECK:STDOUT: !155 = !DILocation(line: 35, column: 3, scope: !150)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'import_class.carbon'
@@ -558,43 +559,43 @@ fn Call(x: Cpp.D) -> Cpp.C {
// CHECK:STDOUT: %struct.X = type { ptr, ptr }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CGetX.Main(ptr sret([16 x i8]) %return) #0 !dbg !11 {
// CHECK:STDOUT: define void @_CGetX.Main(ptr sret([16 x i8]) %return) #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z4Makev.carbon_thunk.(ptr %return), !dbg !15
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: call void @_Z4Makev.carbon_thunk.(ptr %return), !dbg !16
// CHECK:STDOUT: ret void, !dbg !17
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
// CHECK:STDOUT: define internal void @_Z4Makev.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 !17
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !17
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !18
// CHECK:STDOUT: %0 = load ptr, ptr %return.addr, align 8, !tbaa !18
// CHECK:STDOUT: call void @_Z4Makev(ptr dead_on_unwind writable sret(%struct.X) align 8 %0)
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CLet.Main() #0 !dbg !20 {
// CHECK:STDOUT: define void @_CLet.Main() #0 !dbg !21 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc9_27.1.temp = alloca [16 x i8], align 8, !dbg !23
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc9_27.1.temp), !dbg !23
// CHECK:STDOUT: call void @_Z4Makev.carbon_thunk.(ptr %.loc9_27.1.temp), !dbg !23
// CHECK:STDOUT: call void @_ZN1XD1Ev(ptr %.loc9_27.1.temp), !dbg !23
// CHECK:STDOUT: ret void, !dbg !24
// CHECK:STDOUT: %.loc9_27.1.temp = alloca [16 x i8], align 8, !dbg !24
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc9_27.1.temp), !dbg !24
// CHECK:STDOUT: call void @_Z4Makev.carbon_thunk.(ptr %.loc9_27.1.temp), !dbg !24
// CHECK:STDOUT: call void @_ZN1XD1Ev(ptr %.loc9_27.1.temp), !dbg !24
// CHECK:STDOUT: ret void, !dbg !25
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: declare void @_ZN1XD1Ev(ptr noundef nonnull align 8 dead_on_return(16) dereferenceable(16)) unnamed_addr #2
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CVar.Main() #0 !dbg !25 {
// CHECK:STDOUT: define void @_CVar.Main() #0 !dbg !26 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %_.var = alloca [16 x i8], align 8, !dbg !26
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !26
// CHECK:STDOUT: call void @_Z4Makev.carbon_thunk.(ptr %_.var), !dbg !27
// CHECK:STDOUT: call void @_ZN1XD1Ev(ptr %_.var), !dbg !26
// CHECK:STDOUT: ret void, !dbg !28
// CHECK:STDOUT: %_.var = alloca [16 x i8], align 8, !dbg !27
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !27
// CHECK:STDOUT: call void @_Z4Makev.carbon_thunk.(ptr %_.var), !dbg !28
// CHECK:STDOUT: call void @_ZN1XD1Ev(ptr %_.var), !dbg !27
// CHECK:STDOUT: ret void, !dbg !29
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
@@ -622,28 +623,29 @@ fn Call(x: Cpp.D) -> Cpp.C {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "GetX", linkageName: "_CGetX.Main", scope: null, file: !1, line: 6, type: !12, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{!14}
// CHECK:STDOUT: !14 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !15 = !DILocation(line: 6, column: 29, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 22, scope: !11)
// CHECK:STDOUT: !17 = !{!18, !18, i64 0}
// CHECK:STDOUT: !18 = !{!"p1 _ZTS1X", !19, i64 0}
// CHECK:STDOUT: !19 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !20 = distinct !DISubprogram(name: "Let", linkageName: "_CLet.Main", scope: null, file: !1, line: 8, type: !21, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !21 = !DISubroutineType(types: !22)
// CHECK:STDOUT: !22 = !{null}
// CHECK:STDOUT: !23 = !DILocation(line: 9, column: 18, scope: !20)
// CHECK:STDOUT: !24 = !DILocation(line: 8, column: 1, scope: !20)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Var", linkageName: "_CVar.Main", scope: null, file: !1, line: 12, type: !21, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !26 = !DILocation(line: 13, column: 3, scope: !25)
// CHECK:STDOUT: !27 = !DILocation(line: 13, column: 18, scope: !25)
// CHECK:STDOUT: !28 = !DILocation(line: 12, column: 1, scope: !25)
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "GetX", linkageName: "_CGetX.Main", scope: null, file: !1, line: 6, type: !13, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{!15}
// CHECK:STDOUT: !15 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !16 = !DILocation(line: 6, column: 29, scope: !12)
// CHECK:STDOUT: !17 = !DILocation(line: 6, column: 22, scope: !12)
// CHECK:STDOUT: !18 = !{!19, !19, i64 0}
// CHECK:STDOUT: !19 = !{!"p1 _ZTS1X", !20, i64 0}
// CHECK:STDOUT: !20 = !{!"any pointer", !10, i64 0}
// CHECK:STDOUT: !21 = distinct !DISubprogram(name: "Let", linkageName: "_CLet.Main", scope: null, file: !1, line: 8, type: !22, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !22 = !DISubroutineType(types: !23)
// CHECK:STDOUT: !23 = !{null}
// CHECK:STDOUT: !24 = !DILocation(line: 9, column: 18, scope: !21)
// CHECK:STDOUT: !25 = !DILocation(line: 8, column: 1, scope: !21)
// CHECK:STDOUT: !26 = distinct !DISubprogram(name: "Var", linkageName: "_CVar.Main", scope: null, file: !1, line: 12, type: !22, spFlags: DISPFlagDefinition, unit: !0)
// CHECK:STDOUT: !27 = !DILocation(line: 13, column: 3, scope: !26)
// CHECK:STDOUT: !28 = !DILocation(line: 13, column: 18, scope: !26)
// CHECK:STDOUT: !29 = !DILocation(line: 12, column: 1, scope: !26)
// CHECK:STDOUT:
// CHECK:STDOUT: ; ---
// CHECK:STDOUT: ; ModuleID = 'indirect_return_with_args.carbon'
@@ -655,10 +657,10 @@ fn Call(x: Cpp.D) -> Cpp.C {
// CHECK:STDOUT: %class.C = type { i8 }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CCall.Main(ptr sret({}) %return, ptr %x) #0 !dbg !11 {
// CHECK:STDOUT: define void @_CCall.Main(ptr sret({}) %return, ptr %x) #0 !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_Z1f1D.carbon_thunk._(ptr %x, ptr %return), !dbg !17
// CHECK:STDOUT: ret void, !dbg !18
// CHECK:STDOUT: call void @_Z1f1D.carbon_thunk._(ptr %x, ptr %return), !dbg !18
// CHECK:STDOUT: ret void, !dbg !19
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
@@ -668,10 +670,10 @@ fn Call(x: Cpp.D) -> Cpp.C {
// CHECK:STDOUT: %return.addr = alloca ptr, align 8
// CHECK:STDOUT: %agg.tmp = alloca %class.D, align 1
// CHECK:STDOUT: %undef.agg.tmp = alloca %class.C, align 1
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !19
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !22
// CHECK:STDOUT: %1 = load ptr, ptr %return.addr, align 8, !tbaa !22
// CHECK:STDOUT: %2 = load ptr, ptr %.addr, align 8, !tbaa !19
// CHECK:STDOUT: store ptr %0, ptr %.addr, align 8, !tbaa !20
// CHECK:STDOUT: store ptr %return, ptr %return.addr, align 8, !tbaa !23
// CHECK:STDOUT: %1 = load ptr, ptr %return.addr, align 8, !tbaa !23
// CHECK:STDOUT: %2 = load ptr, ptr %.addr, align 8, !tbaa !20
// CHECK:STDOUT: call void @_Z1f1D()
// CHECK:STDOUT: ret void
// CHECK:STDOUT: }
@@ -693,21 +695,22 @@ fn Call(x: Cpp.D) -> Cpp.C {
// CHECK:STDOUT: !4 = !{i32 7, !"uwtable", i32 2}
// CHECK:STDOUT: !5 = !{i32 7, !"Dwarf Version", i32 5}
// CHECK:STDOUT: !6 = !{i32 2, !"Debug Info Version", i32 3}
// CHECK:STDOUT: !7 = !{!8, !8, i64 0}
// CHECK:STDOUT: !8 = !{!"int", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"omnipotent char", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !11 = distinct !DISubprogram(name: "Call", linkageName: "_CCall.Main", scope: null, file: !1, line: 10, type: !12, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !15)
// CHECK:STDOUT: !12 = !DISubroutineType(types: !13)
// CHECK:STDOUT: !13 = !{!14, !14}
// CHECK:STDOUT: !14 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !15 = !{!16}
// CHECK:STDOUT: !16 = !DILocalVariable(arg: 1, scope: !11, type: !14)
// CHECK:STDOUT: !17 = !DILocation(line: 11, column: 10, scope: !11)
// CHECK:STDOUT: !18 = !DILocation(line: 11, column: 3, scope: !11)
// CHECK:STDOUT: !19 = !{!20, !20, i64 0}
// CHECK:STDOUT: !20 = !{!"p1 _ZTS1D", !21, i64 0}
// CHECK:STDOUT: !21 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !22 = !{!23, !23, i64 0}
// CHECK:STDOUT: !23 = !{!"p1 _ZTS1C", !21, i64 0}
// CHECK:STDOUT: !7 = !{!8, !9, i64 0}
// CHECK:STDOUT: !8 = !{!"__libc_errno", !9, i64 0}
// CHECK:STDOUT: !9 = !{!"int", !10, i64 0}
// CHECK:STDOUT: !10 = !{!"omnipotent char", !11, i64 0}
// CHECK:STDOUT: !11 = !{!"Simple C++ TBAA"}
// CHECK:STDOUT: !12 = distinct !DISubprogram(name: "Call", linkageName: "_CCall.Main", scope: null, file: !1, line: 10, type: !13, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !16)
// CHECK:STDOUT: !13 = !DISubroutineType(types: !14)
// CHECK:STDOUT: !14 = !{!15, !15}
// CHECK:STDOUT: !15 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !16 = !{!17}
// CHECK:STDOUT: !17 = !DILocalVariable(arg: 1, scope: !12, type: !15)
// CHECK:STDOUT: !18 = !DILocation(line: 11, column: 10, scope: !12)
// CHECK:STDOUT: !19 = !DILocation(line: 11, column: 3, scope: !12)
// CHECK:STDOUT: !20 = !{!21, !21, i64 0}
// CHECK:STDOUT: !21 = !{!"p1 _ZTS1D", !22, i64 0}
// CHECK:STDOUT: !22 = !{!"any pointer", !10, i64 0}
// CHECK:STDOUT: !23 = !{!24, !24, i64 0}
// CHECK:STDOUT: !24 = !{!"p1 _ZTS1C", !22, i64 0}
// CHECK:STDOUT: