Fix cross-package signature mismatches. (#7232)

Fixes link failures when referencing a symbol involving a fingerprint
from a different package.

Previously we included the `Namespace`'s `import_id` as part of its
fingerprint, which caused local and imported namespaces to get different
fingerprints. We now store the `import_id` on the `NameScope` instead of
on the `Namespace` inst to avoid this problem.

Also, when we reach a package-level `NameScopeId`, consistently
fingerprint it as a (package name, library name) pair. Previously the
fingerprinting depended on whether it was imported or not, as an
imported `NameScopeId` had a parent scope (the current package). We need
to include the library name here so that private entities with the same
name in different libraries have different fingerprints.
This commit is contained in:
Richard Smith
2026-05-21 00:02:29 +00:00
committed by GitHub
parent 1231098c14
commit 05cc09daca
662 changed files with 51181 additions and 50920 deletions
@@ -166,18 +166,18 @@ auto DoThing() -> void {
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.Derived.Main"(ptr %self) #6 !dbg !29 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.12e0d0434542305a:core.Destroy.Core"(ptr %self), !dbg !32
// CHECK:STDOUT: call void @"_COp.dc7802eff02bba82:core.Destroy.Core"(ptr %self), !dbg !32
// CHECK:STDOUT: ret void, !dbg !32
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.bfe31446004e2b71:core.Destroy.Core"(ptr %self) #5 !dbg !33 {
// CHECK:STDOUT: define weak_odr void @"_COp.9262bcc12ced4e1e:core.Destroy.Core"(ptr %self) #5 !dbg !33 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !36
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.12e0d0434542305a:core.Destroy.Core"(ptr %self) #5 !dbg !37 {
// CHECK:STDOUT: define weak_odr void @"_COp.dc7802eff02bba82:core.Destroy.Core"(ptr %self) #5 !dbg !37 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !40
// CHECK:STDOUT: }
@@ -297,11 +297,11 @@ auto DoThing() -> void {
// CHECK:STDOUT: !30 = !{!31}
// CHECK:STDOUT: !31 = !DILocalVariable(arg: 1, scope: !29, type: !21)
// CHECK:STDOUT: !32 = !DILocation(line: 22, column: 1, scope: !29)
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.bfe31446004e2b71:core.Destroy.Core", scope: null, file: !6, line: 22, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !34)
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.9262bcc12ced4e1e:core.Destroy.Core", scope: null, file: !6, line: 22, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !34)
// CHECK:STDOUT: !34 = !{!35}
// CHECK:STDOUT: !35 = !DILocalVariable(arg: 1, scope: !33, type: !21)
// CHECK:STDOUT: !36 = !DILocation(line: 22, column: 1, scope: !33)
// CHECK:STDOUT: !37 = distinct !DISubprogram(name: "Op", linkageName: "_COp.12e0d0434542305a:core.Destroy.Core", scope: null, file: !6, line: 22, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !38)
// CHECK:STDOUT: !37 = distinct !DISubprogram(name: "Op", linkageName: "_COp.dc7802eff02bba82:core.Destroy.Core", scope: null, file: !6, line: 22, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !38)
// CHECK:STDOUT: !38 = !{!39}
// CHECK:STDOUT: !39 = !DILocalVariable(arg: 1, scope: !37, type: !21)
// CHECK:STDOUT: !40 = !DILocation(line: 22, column: 1, scope: !37)
@@ -201,7 +201,7 @@ void delete_new_Base() {
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.Final.Main"(ptr %self) #6 !dbg !22 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.4472d163614a5082:core.Destroy.Core"(ptr %self), !dbg !28
// CHECK:STDOUT: call void @"_COp.bbe15d81bea73f45:core.Destroy.Core"(ptr %self), !dbg !28
// CHECK:STDOUT: ret void, !dbg !28
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -209,13 +209,13 @@ void delete_new_Base() {
// CHECK:STDOUT: declare void @_ZN1AD1Ev(ptr noundef nonnull align 8 dead_on_return(8) dereferenceable(8)) unnamed_addr #7
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.446491dd079aaad2:core.Destroy.Core"(ptr %self) #8 !dbg !29 {
// CHECK:STDOUT: define weak_odr void @"_COp.bce205344e07c31d:core.Destroy.Core"(ptr %self) #8 !dbg !29 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !32
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.4472d163614a5082:core.Destroy.Core"(ptr %self) #8 !dbg !33 {
// CHECK:STDOUT: define weak_odr void @"_COp.bbe15d81bea73f45:core.Destroy.Core"(ptr %self) #8 !dbg !33 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !36
// CHECK:STDOUT: }
@@ -232,12 +232,12 @@ void delete_new_Base() {
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.Base.Main"(ptr %self) #6 !dbg !41 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.96a711151205ee34:core.Destroy.Core"(ptr %self), !dbg !44
// CHECK:STDOUT: call void @"_COp.890f67314d492134:core.Destroy.Core"(ptr %self), !dbg !44
// CHECK:STDOUT: ret void, !dbg !44
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.96a711151205ee34:core.Destroy.Core"(ptr %self) #8 !dbg !45 {
// CHECK:STDOUT: define weak_odr void @"_COp.890f67314d492134:core.Destroy.Core"(ptr %self) #8 !dbg !45 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !48
// CHECK:STDOUT: }
@@ -380,11 +380,11 @@ void delete_new_Base() {
// CHECK:STDOUT: !26 = !{!27}
// CHECK:STDOUT: !27 = !DILocalVariable(arg: 1, scope: !22, type: !25)
// CHECK:STDOUT: !28 = !DILocation(line: 12, column: 1, scope: !22)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp.446491dd079aaad2:core.Destroy.Core", scope: null, file: !6, line: 12, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !30)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp.bce205344e07c31d:core.Destroy.Core", scope: null, file: !6, line: 12, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !30)
// CHECK:STDOUT: !30 = !{!31}
// CHECK:STDOUT: !31 = !DILocalVariable(arg: 1, scope: !29, type: !25)
// CHECK:STDOUT: !32 = !DILocation(line: 12, column: 1, scope: !29)
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.4472d163614a5082:core.Destroy.Core", scope: null, file: !6, line: 12, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !34)
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.bbe15d81bea73f45:core.Destroy.Core", scope: null, file: !6, line: 12, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !34)
// CHECK:STDOUT: !34 = !{!35}
// CHECK:STDOUT: !35 = !DILocalVariable(arg: 1, scope: !33, type: !25)
// CHECK:STDOUT: !36 = !DILocation(line: 12, column: 1, scope: !33)
@@ -396,7 +396,7 @@ void delete_new_Base() {
// CHECK:STDOUT: !42 = !{!43}
// CHECK:STDOUT: !43 = !DILocalVariable(arg: 1, scope: !41, type: !25)
// CHECK:STDOUT: !44 = !DILocation(line: 17, column: 1, scope: !41)
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Op", linkageName: "_COp.96a711151205ee34:core.Destroy.Core", scope: null, file: !6, line: 17, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !46)
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Op", linkageName: "_COp.890f67314d492134:core.Destroy.Core", scope: null, file: !6, line: 17, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !46)
// CHECK:STDOUT: !46 = !{!47}
// CHECK:STDOUT: !47 = !DILocalVariable(arg: 1, scope: !45, type: !25)
// CHECK:STDOUT: !48 = !DILocation(line: 17, column: 1, scope: !45)
+20 -20
View File
@@ -281,7 +281,7 @@ fn Four() {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %_.var = alloca [8 x i8], align 1, !dbg !14
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b"(ptr %_.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca"(ptr %_.var), !dbg !14
// CHECK:STDOUT: ret void, !dbg !15
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -296,7 +296,7 @@ fn Four() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp"(ptr sret([8 x i8]) %return) #2 !dbg !19 {
// CHECK:STDOUT: define void @"_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp"(ptr sret([8 x i8]) %return) #2 !dbg !19 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN1CC1Ev.carbon_thunk.(ptr %return), !dbg !24
// CHECK:STDOUT: ret void, !dbg !24
@@ -306,8 +306,8 @@ fn Four() {
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #3
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b"(ptr sret([8 x i8]) %return) #0 !dbg !25 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp"(ptr %return), !dbg !27
// CHECK:STDOUT: define linkonce_odr void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca"(ptr sret([8 x i8]) %return) #0 !dbg !25 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp"(ptr %return), !dbg !27
// CHECK:STDOUT: ret void, !dbg !28
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -353,13 +353,13 @@ fn Four() {
// CHECK:STDOUT: !16 = !{!17, !17, i64 0}
// CHECK:STDOUT: !17 = !{!"p1 _ZTS1C", !18, i64 0}
// CHECK:STDOUT: !18 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !19 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp", scope: null, file: !20, line: 4, type: !21, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !19 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp", scope: null, file: !20, line: 4, type: !21, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !20 = !DIFile(filename: "./default.h", directory: "")
// CHECK:STDOUT: !21 = !DISubroutineType(types: !22)
// CHECK:STDOUT: !22 = !{!23}
// CHECK:STDOUT: !23 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !24 = !DILocation(line: 4, column: 3, scope: !19)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b", scope: null, file: !26, line: 9, type: !21, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca", scope: null, file: !26, line: 9, type: !21, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !26 = !DIFile(filename: "min_prelude/parts/default.carbon", directory: "")
// CHECK:STDOUT: !27 = !DILocation(line: 9, column: 28, scope: !25)
// CHECK:STDOUT: !28 = !DILocation(line: 9, column: 21, scope: !25)
@@ -388,11 +388,11 @@ fn Four() {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc8_65.1.temp), !dbg !14
// CHECK:STDOUT: call void @_ZN26ImplicitlyDefaultedDefaultC1Ev.carbon_thunk.(ptr %.loc8_65.1.temp), !dbg !14
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var.loc9), !dbg !15
// CHECK:STDOUT: call void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.22b4681b019423d7"(ptr %_.var.loc9), !dbg !15
// CHECK:STDOUT: call void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2db09a503899761f"(ptr %_.var.loc9), !dbg !15
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc12_65.1.temp), !dbg !16
// CHECK:STDOUT: call void @_ZN26ExplicitlyDefaultedDefaultC1Ev.carbon_thunk.(ptr %.loc12_65.1.temp), !dbg !16
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var.loc13), !dbg !17
// CHECK:STDOUT: call void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.1a27c303748a2360"(ptr %_.var.loc13), !dbg !17
// CHECK:STDOUT: call void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.0dfbcd9a7c1791ba"(ptr %_.var.loc13), !dbg !17
// CHECK:STDOUT: ret void, !dbg !18
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -407,7 +407,7 @@ fn Four() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Default.2e5fb550c65543cf.Core:ImplicitlyDefaultedDefault.Cpp"(ptr sret([4 x i8]) %return) #2 !dbg !22 {
// CHECK:STDOUT: define void @"_COp:thunk:Default.40902cf3dea87d9c.Core:ImplicitlyDefaultedDefault.Cpp"(ptr sret([4 x i8]) %return) #2 !dbg !22 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN26ImplicitlyDefaultedDefaultC1Ev.carbon_thunk.(ptr %return), !dbg !27
// CHECK:STDOUT: ret void, !dbg !27
@@ -424,7 +424,7 @@ fn Four() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Default.cad83ce9b7db87bf.Core:ExplicitlyDefaultedDefault.Cpp"(ptr sret([4 x i8]) %return) #2 !dbg !30 {
// CHECK:STDOUT: define void @"_COp:thunk:Default.f7ced4a20f885cf5.Core:ExplicitlyDefaultedDefault.Cpp"(ptr sret([4 x i8]) %return) #2 !dbg !30 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN26ExplicitlyDefaultedDefaultC1Ev.carbon_thunk.(ptr %return), !dbg !31
// CHECK:STDOUT: ret void, !dbg !31
@@ -434,14 +434,14 @@ fn Four() {
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #3
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.22b4681b019423d7"(ptr sret([4 x i8]) %return) #0 !dbg !32 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.2e5fb550c65543cf.Core:ImplicitlyDefaultedDefault.Cpp"(ptr %return), !dbg !34
// CHECK:STDOUT: define linkonce_odr void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2db09a503899761f"(ptr sret([4 x i8]) %return) #0 !dbg !32 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.40902cf3dea87d9c.Core:ImplicitlyDefaultedDefault.Cpp"(ptr %return), !dbg !34
// CHECK:STDOUT: ret void, !dbg !35
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.1a27c303748a2360"(ptr sret([4 x i8]) %return) #0 !dbg !36 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.cad83ce9b7db87bf.Core:ExplicitlyDefaultedDefault.Cpp"(ptr %return), !dbg !37
// CHECK:STDOUT: define linkonce_odr void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.0dfbcd9a7c1791ba"(ptr sret([4 x i8]) %return) #0 !dbg !36 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.f7ced4a20f885cf5.Core:ExplicitlyDefaultedDefault.Cpp"(ptr %return), !dbg !37
// CHECK:STDOUT: ret void, !dbg !38
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -503,7 +503,7 @@ fn Four() {
// CHECK:STDOUT: !19 = !{!20, !20, i64 0}
// CHECK:STDOUT: !20 = !{!"p1 _ZTS26ImplicitlyDefaultedDefault", !21, i64 0}
// CHECK:STDOUT: !21 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.2e5fb550c65543cf.Core:ImplicitlyDefaultedDefault.Cpp", scope: null, file: !23, line: 2, type: !24, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.40902cf3dea87d9c.Core:ImplicitlyDefaultedDefault.Cpp", scope: null, file: !23, line: 2, type: !24, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !23 = !DIFile(filename: "./defaulted_default.h", directory: "")
// CHECK:STDOUT: !24 = !DISubroutineType(types: !25)
// CHECK:STDOUT: !25 = !{!26}
@@ -511,13 +511,13 @@ fn Four() {
// CHECK:STDOUT: !27 = !DILocation(line: 2, column: 8, scope: !22)
// CHECK:STDOUT: !28 = !{!29, !29, i64 0}
// CHECK:STDOUT: !29 = !{!"p1 _ZTS26ExplicitlyDefaultedDefault", !21, i64 0}
// CHECK:STDOUT: !30 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.cad83ce9b7db87bf.Core:ExplicitlyDefaultedDefault.Cpp", scope: null, file: !23, line: 7, type: !24, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !30 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.f7ced4a20f885cf5.Core:ExplicitlyDefaultedDefault.Cpp", scope: null, file: !23, line: 7, type: !24, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !31 = !DILocation(line: 7, column: 3, scope: !30)
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "Op", linkageName: "_COp.d288d62be0e5d791:DefaultOrUnformed.Core.22b4681b019423d7", scope: null, file: !33, line: 9, type: !24, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "Op", linkageName: "_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2db09a503899761f", scope: null, file: !33, line: 9, type: !24, spFlags: DISPFlagDefinition, unit: !5)
// 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: !36 = distinct !DISubprogram(name: "Op", linkageName: "_COp.d288d62be0e5d791:DefaultOrUnformed.Core.1a27c303748a2360", scope: null, file: !33, line: 9, type: !24, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "Op", linkageName: "_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.0dfbcd9a7c1791ba", scope: null, file: !33, line: 9, type: !24, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !37 = !DILocation(line: 9, column: 28, scope: !36)
// CHECK:STDOUT: !38 = !DILocation(line: 9, column: 21, scope: !36)
// CHECK:STDOUT: !39 = !{!40, !8, i64 0}
@@ -552,7 +552,7 @@ fn Four() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Copy.692da64e78c7deec.Core:Copy.Cpp"(ptr sret([4 x i8]) %return, ptr %self) #2 !dbg !22 {
// CHECK:STDOUT: define void @"_COp:thunk:Copy.83073f2d17ed2f9e.Core:Copy.Cpp"(ptr sret([4 x i8]) %return, ptr %self) #2 !dbg !22 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN4CopyC1ERKS_.carbon_thunk._(ptr %self, ptr %return), !dbg !26
// CHECK:STDOUT: ret void, !dbg !26
@@ -595,7 +595,7 @@ fn Four() {
// CHECK:STDOUT: !19 = !{!20, !20, i64 0}
// CHECK:STDOUT: !20 = !{!"p1 _ZTS4Copy", !21, i64 0}
// CHECK:STDOUT: !21 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Copy.692da64e78c7deec.Core:Copy.Cpp", scope: null, file: !23, line: 5, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !24)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Copy.83073f2d17ed2f9e.Core:Copy.Cpp", scope: null, file: !23, line: 5, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !24)
// CHECK:STDOUT: !23 = !DIFile(filename: "./copy.h", directory: "")
// CHECK:STDOUT: !24 = !{!25}
// CHECK:STDOUT: !25 = !DILocalVariable(arg: 1, scope: !22, type: !14)
+3 -3
View File
@@ -396,7 +396,7 @@ fn MyF() -> i32 {
// 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.7e389eab4a7e5487:core.Destroy.Core"(ptr %value.var), !dbg !15
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %value.var), !dbg !15
// CHECK:STDOUT: ret i32 %.loc14, !dbg !25
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -439,7 +439,7 @@ 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.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #0 !dbg !26 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #0 !dbg !26 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !31
// CHECK:STDOUT: }
@@ -486,7 +486,7 @@ fn MyF() -> i32 {
// 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.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 11, type: !27, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !26 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 11, type: !27, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !27 = !DISubroutineType(types: !28)
// CHECK:STDOUT: !28 = !{null, !14}
// CHECK:STDOUT: !29 = !{!30}
+3 -3
View File
@@ -47,12 +47,12 @@ fn Call() -> i32 {
// 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.7e389eab4a7e5487:core.Destroy.Core"(ptr %n.var), !dbg !18
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %n.var), !dbg !18
// CHECK:STDOUT: ret i32 %.loc24, !dbg !21
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #1 !dbg !22 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #1 !dbg !22 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: }
@@ -90,7 +90,7 @@ fn Call() -> i32 {
// 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.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 22, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !25)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 22, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !25)
// CHECK:STDOUT: !23 = !DISubroutineType(types: !24)
// CHECK:STDOUT: !24 = !{null, !17}
// CHECK:STDOUT: !25 = !{!26}
+8 -8
View File
@@ -291,7 +291,7 @@ fn F(ref r: Cpp.A) {
// CHECK:STDOUT:
// CHECK:STDOUT: %struct.NeedThunk = type { i8 }
// CHECK:STDOUT:
// CHECK:STDOUT: @int_1.30e = internal constant i8 1
// CHECK:STDOUT: @int_1.9eb = internal constant i8 1
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CCall.Main(ptr %n) #0 !dbg !11 {
@@ -299,11 +299,11 @@ fn F(ref r: Cpp.A) {
// CHECK:STDOUT: %.loc7_14.3.temp = alloca i8, align 1, !dbg !17
// CHECK:STDOUT: %.loc8_14.3.temp = alloca i8, align 1, !dbg !18
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_14.3.temp), !dbg !17
// CHECK:STDOUT: call void @_ZNK9NeedThunk8ImplicitEa.carbon_thunk.__(ptr %n, ptr @int_1.30e), !dbg !19
// CHECK:STDOUT: call void @_ZNK9NeedThunk8ImplicitEa.carbon_thunk.__(ptr %n, ptr @int_1.9eb), !dbg !19
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc8_14.3.temp), !dbg !18
// CHECK:STDOUT: call void @_ZNH9NeedThunk8ExplicitES_a.carbon_thunk.__(ptr %n, ptr @int_1.30e), !dbg !20
// CHECK:STDOUT: call void @"_COp.43bece552030817c:core.Destroy.Core"(ptr @int_1.30e), !dbg !18
// CHECK:STDOUT: call void @"_COp.43bece552030817c:core.Destroy.Core"(ptr @int_1.30e), !dbg !17
// CHECK:STDOUT: call void @_ZNH9NeedThunk8ExplicitES_a.carbon_thunk.__(ptr %n, ptr @int_1.9eb), !dbg !20
// CHECK:STDOUT: call void @"_COp.4bf3b2f84a23e67d:core.Destroy.Core"(ptr @int_1.9eb), !dbg !18
// CHECK:STDOUT: call void @"_COp.4bf3b2f84a23e67d:core.Destroy.Core"(ptr @int_1.9eb), !dbg !17
// CHECK:STDOUT: ret void, !dbg !21
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -337,7 +337,7 @@ fn F(ref r: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.43bece552030817c:core.Destroy.Core"(ptr %self) #0 !dbg !29 {
// CHECK:STDOUT: define weak_odr void @"_COp.4bf3b2f84a23e67d:core.Destroy.Core"(ptr %self) #0 !dbg !29 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !35
// CHECK:STDOUT: }
@@ -350,7 +350,7 @@ fn F(ref r: Cpp.A) {
// CHECK:STDOUT: declare void @_ZNH9NeedThunk8ExplicitES_a(i8 noundef signext) #3
// CHECK:STDOUT:
// CHECK:STDOUT: ; uselistorder directives
// CHECK:STDOUT: uselistorder ptr @"_COp.43bece552030817c:core.Destroy.Core", { 1, 0 }
// CHECK:STDOUT: uselistorder ptr @"_COp.4bf3b2f84a23e67d:core.Destroy.Core", { 1, 0 }
// CHECK:STDOUT: uselistorder ptr @llvm.lifetime.start.p0, { 1, 0 }
// CHECK:STDOUT:
// CHECK:STDOUT: attributes #0 = { nounwind }
@@ -391,7 +391,7 @@ fn F(ref r: Cpp.A) {
// CHECK:STDOUT: !26 = !{!"p1 omnipotent char", !24, i64 0}
// CHECK:STDOUT: !27 = !{}
// CHECK:STDOUT: !28 = !{!9, !9, i64 0}
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp.43bece552030817c:core.Destroy.Core", scope: null, file: !6, line: 8, type: !30, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !33)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp.4bf3b2f84a23e67d:core.Destroy.Core", scope: null, file: !6, line: 8, type: !30, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !33)
// CHECK:STDOUT: !30 = !DISubroutineType(types: !31)
// CHECK:STDOUT: !31 = !{null, !32}
// CHECK:STDOUT: !32 = !DIBasicType(name: "int", size: 8, encoding: DW_ATE_signed)
+21 -21
View File
@@ -59,7 +59,7 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc12_18.2.temp = alloca ptr, align 8, !dbg !14
// CHECK:STDOUT: %.loc14_22.1.temp = alloca ptr, align 8, !dbg !15
// CHECK:STDOUT: %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.a5972e826b98ae3c.Core.b88d1103f417c6d4"(ptr poison), !dbg !14
// CHECK:STDOUT: %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.7b6a382d04a36247.Core.c8fd090a2e741f70"(ptr poison), !dbg !14
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc12_18.2.temp), !dbg !14
// CHECK:STDOUT: store ptr %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call, ptr %.loc12_18.2.temp, align 8, !dbg !14
// CHECK:STDOUT: %.loc12_18.4 = load ptr, ptr %.loc12_18.2.temp, align 8, !dbg !14
@@ -68,8 +68,8 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc14_22.1.temp), !dbg !15
// CHECK:STDOUT: store ptr %Cpp.nullptr_t.as.Copy.impl.Op.call, ptr %.loc14_22.1.temp, align 8, !dbg !15
// CHECK:STDOUT: call void @_Z11TakeNullptrDn.carbon_thunk._(ptr %.loc14_22.1.temp), !dbg !17
// CHECK:STDOUT: call void @"_COp.705e422c84320121:core.Destroy.Core"(ptr %.loc14_22.1.temp), !dbg !15
// CHECK:STDOUT: call void @"_COp.e34c165b4a1e692a:core.Destroy.Core"(ptr %.loc12_18.2.temp), !dbg !14
// CHECK:STDOUT: call void @"_COp.5f1c33499946866e:core.Destroy.Core"(ptr %.loc14_22.1.temp), !dbg !15
// CHECK:STDOUT: call void @"_COp.ffb455139f965851:core.Destroy.Core"(ptr %.loc12_18.2.temp), !dbg !14
// CHECK:STDOUT: ret void, !dbg !18
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -88,19 +88,19 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: declare ptr @"_COp.NullptrT.CppCompat.Core:Copy.Core"(ptr)
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.705e422c84320121:core.Destroy.Core"(ptr %self) #0 !dbg !22 {
// CHECK:STDOUT: define weak_odr void @"_COp.5f1c33499946866e:core.Destroy.Core"(ptr %self) #0 !dbg !22 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !28
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.ca2ce9262234b385:core.Destroy.Core"(ptr %self) #0 !dbg !29 {
// CHECK:STDOUT: define weak_odr void @"_COp.3fe7740c8ce31fb1:core.Destroy.Core"(ptr %self) #0 !dbg !29 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !32
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.e34c165b4a1e692a:core.Destroy.Core"(ptr %self) #0 !dbg !33 {
// CHECK:STDOUT: define weak_odr void @"_COp.ffb455139f965851:core.Destroy.Core"(ptr %self) #0 !dbg !33 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !36
// CHECK:STDOUT: }
@@ -121,7 +121,7 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: store ptr %Cpp.nullptr_t.as.Copy.impl.Op.call.loc22, ptr %a.var, align 8, !dbg !43
// CHECK:STDOUT: %.loc23 = load ptr, ptr %a.var, align 8, !dbg !45
// CHECK:STDOUT: %Cpp.nullptr_t.as.Copy.impl.Op.call.loc23 = call ptr @"_COp.NullptrT.CppCompat.Core:Copy.Core"(ptr %.loc23), !dbg !45
// CHECK:STDOUT: call void @"_COp.705e422c84320121:core.Destroy.Core"(ptr %a.var), !dbg !43
// CHECK:STDOUT: call void @"_COp.5f1c33499946866e:core.Destroy.Core"(ptr %a.var), !dbg !43
// CHECK:STDOUT: ret ptr %Cpp.nullptr_t.as.Copy.impl.Op.call.loc23, !dbg !46
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -132,8 +132,8 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %a.var), !dbg !48
// CHECK:STDOUT: call void @_Z13ReturnNullptrv.carbon_thunk.(ptr %a.var), !dbg !49
// CHECK:STDOUT: %.loc28_10 = load ptr, ptr %a.var, align 8, !dbg !50
// CHECK:STDOUT: %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.a5972e826b98ae3c.Core.b88d1103f417c6d4"(ptr %.loc28_10), !dbg !51
// CHECK:STDOUT: call void @"_COp.705e422c84320121:core.Destroy.Core"(ptr %a.var), !dbg !48
// CHECK:STDOUT: %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.7b6a382d04a36247.Core.c8fd090a2e741f70"(ptr %.loc28_10), !dbg !51
// CHECK:STDOUT: call void @"_COp.5f1c33499946866e:core.Destroy.Core"(ptr %a.var), !dbg !48
// CHECK:STDOUT: ret ptr %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call, !dbg !51
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -155,21 +155,21 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc32_28.1.temp), !dbg !55
// CHECK:STDOUT: call void @_Z13ReturnNullptrv.carbon_thunk.(ptr %.loc32_28.1.temp), !dbg !55
// CHECK:STDOUT: %.loc32_28.4 = load ptr, ptr %.loc32_28.1.temp, align 8, !dbg !55
// CHECK:STDOUT: %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.a5972e826b98ae3c.Core.b88d1103f417c6d4"(ptr %.loc32_28.4), !dbg !56
// CHECK:STDOUT: call void @"_COp.705e422c84320121:core.Destroy.Core"(ptr %.loc32_28.1.temp), !dbg !55
// CHECK:STDOUT: %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.7b6a382d04a36247.Core.c8fd090a2e741f70"(ptr %.loc32_28.4), !dbg !56
// CHECK:STDOUT: call void @"_COp.5f1c33499946866e:core.Destroy.Core"(ptr %.loc32_28.1.temp), !dbg !55
// CHECK:STDOUT: ret ptr %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call, !dbg !56
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define ptr @_CConvertNullptrConstant.Main() #0 !dbg !57 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.a5972e826b98ae3c.Core.b88d1103f417c6d4"(ptr poison), !dbg !58
// CHECK:STDOUT: %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.7b6a382d04a36247.Core.c8fd090a2e741f70"(ptr poison), !dbg !58
// CHECK:STDOUT: ret ptr %Cpp.nullptr_t.as.ImplicitAs.impl.Convert.call, !dbg !58
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.a5972e826b98ae3c.Core.b88d1103f417c6d4"(ptr %self) #0 !dbg !59 {
// CHECK:STDOUT: %1 = call ptr @_CNone.Optional.Core.06b91a9f98f18410(), !dbg !65
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.7b6a382d04a36247.Core.c8fd090a2e741f70"(ptr %self) #0 !dbg !59 {
// CHECK:STDOUT: %1 = call ptr @_CNone.Optional.Core.e51fa37fd255d8de(), !dbg !65
// CHECK:STDOUT: ret ptr %1, !dbg !66
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -179,7 +179,7 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: declare ptr @_CMake.NullptrT.CppCompat.Core()
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @_CNone.Optional.Core.06b91a9f98f18410() #0 !dbg !67 {
// CHECK:STDOUT: define linkonce_odr ptr @_CNone.Optional.Core.e51fa37fd255d8de() #0 !dbg !67 {
// CHECK:STDOUT: ret ptr null, !dbg !69
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -188,7 +188,7 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: declare ptr @_Z13ReturnNullptrv() #1
// CHECK:STDOUT:
// CHECK:STDOUT: ; uselistorder directives
// CHECK:STDOUT: uselistorder ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.a5972e826b98ae3c.Core.b88d1103f417c6d4", { 3, 2, 1, 0 }
// CHECK:STDOUT: uselistorder ptr @"_CConvert.NullptrT.CppCompat.Core:ImplicitAs.7b6a382d04a36247.Core.c8fd090a2e741f70", { 3, 2, 1, 0 }
// CHECK:STDOUT: uselistorder ptr @llvm.lifetime.start.p0, { 4, 3, 2, 1, 0 }
// CHECK:STDOUT:
// CHECK:STDOUT: attributes #0 = { nounwind }
@@ -222,18 +222,18 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: !19 = !{!20, !20, i64 0}
// CHECK:STDOUT: !20 = !{!"p1 std::nullptr_t", !21, i64 0}
// CHECK:STDOUT: !21 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp.705e422c84320121:core.Destroy.Core", scope: null, file: !6, line: 14, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !26)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp.5f1c33499946866e:core.Destroy.Core", scope: null, file: !6, line: 14, type: !23, spFlags: DISPFlagDefinition, unit: !5, 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: 14, column: 19, scope: !22)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp.ca2ce9262234b385:core.Destroy.Core", scope: null, file: !6, line: 12, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !30)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp.3fe7740c8ce31fb1:core.Destroy.Core", scope: null, file: !6, line: 12, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !30)
// CHECK:STDOUT: !30 = !{!31}
// CHECK:STDOUT: !31 = !DILocalVariable(arg: 1, scope: !29, type: !25)
// CHECK:STDOUT: !32 = !DILocation(line: 12, column: 15, scope: !29)
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.e34c165b4a1e692a:core.Destroy.Core", scope: null, file: !6, line: 12, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !34)
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.ffb455139f965851:core.Destroy.Core", scope: null, file: !6, line: 12, type: !23, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !34)
// CHECK:STDOUT: !34 = !{!35}
// CHECK:STDOUT: !35 = !DILocalVariable(arg: 1, scope: !33, type: !25)
// CHECK:STDOUT: !36 = !DILocation(line: 12, column: 15, scope: !33)
@@ -259,7 +259,7 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: !56 = !DILocation(line: 32, column: 3, scope: !54)
// CHECK:STDOUT: !57 = distinct !DISubprogram(name: "ConvertNullptrConstant", linkageName: "_CConvertNullptrConstant.Main", scope: null, file: !6, line: 35, type: !38, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !58 = !DILocation(line: 36, column: 3, scope: !57)
// CHECK:STDOUT: !59 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.NullptrT.CppCompat.Core:ImplicitAs.a5972e826b98ae3c.Core.b88d1103f417c6d4", scope: null, file: !60, line: 51, type: !61, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !63)
// CHECK:STDOUT: !59 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.NullptrT.CppCompat.Core:ImplicitAs.7b6a382d04a36247.Core.c8fd090a2e741f70", scope: null, file: !60, line: 51, type: !61, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !63)
// CHECK:STDOUT: !60 = !DIFile(filename: "{{.*}}/prelude/types/cpp/nullptr.carbon", directory: "")
// CHECK:STDOUT: !61 = !DISubroutineType(types: !62)
// CHECK:STDOUT: !62 = !{!25, !25}
@@ -267,6 +267,6 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
// CHECK:STDOUT: !64 = !DILocalVariable(arg: 1, scope: !59, type: !25)
// CHECK:STDOUT: !65 = !DILocation(line: 52, column: 14, scope: !59)
// CHECK:STDOUT: !66 = !DILocation(line: 52, column: 7, scope: !59)
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "None", linkageName: "_CNone.Optional.Core.06b91a9f98f18410", scope: null, file: !68, line: 27, type: !38, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "None", linkageName: "_CNone.Optional.Core.e51fa37fd255d8de", scope: null, file: !68, line: 27, type: !38, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !68 = !DIFile(filename: "{{.*}}/prelude/types/optional.carbon", directory: "")
// CHECK:STDOUT: !69 = !DILocation(line: 28, column: 5, scope: !67)
+24 -24
View File
@@ -88,7 +88,7 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CDriver.Main(ptr %x, ptr %y) #0 !dbg !11 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CCheckEqWith.Main.795833dfa91e6085(ptr %x, ptr %y), !dbg !18
// CHECK:STDOUT: call void @_CCheckEqWith.Main.8514cfa07ba3e7b7(ptr %x, ptr %y), !dbg !18
// CHECK:STDOUT: ret void, !dbg !19
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -145,7 +145,7 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define i1 @"_CEqual:thunk:EqWith.95dfad7558f19bf5.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !28 {
// CHECK:STDOUT: define i1 @"_CEqual:thunk:EqWith.f46538683c1a9318.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.3.temp = alloca i1, align 1, !dbg !34
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.3.temp), !dbg !34
@@ -155,7 +155,7 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define i1 @"_CNotEqual:thunk:EqWith.95dfad7558f19bf5.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !35 {
// CHECK:STDOUT: define i1 @"_CNotEqual:thunk:EqWith.f46538683c1a9318.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !35 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.3.temp = alloca i1, align 1, !dbg !39
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.3.temp), !dbg !39
@@ -165,10 +165,10 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr void @_CCheckEqWith.Main.795833dfa91e6085(ptr %x, ptr %y) #0 !dbg !40 {
// CHECK:STDOUT: define linkonce_odr void @_CCheckEqWith.Main.8514cfa07ba3e7b7(ptr %x, ptr %y) #0 !dbg !40 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %EqWith.WithSelf.Equal.call = call i1 @"_CEqual:thunk:EqWith.95dfad7558f19bf5.Core:Cpp"(ptr %x, ptr %y), !dbg !44
// CHECK:STDOUT: %EqWith.WithSelf.NotEqual.call = call i1 @"_CNotEqual:thunk:EqWith.95dfad7558f19bf5.Core:Cpp"(ptr %x, ptr %y), !dbg !45
// CHECK:STDOUT: %EqWith.WithSelf.Equal.call = call i1 @"_CEqual:thunk:EqWith.f46538683c1a9318.Core:Cpp"(ptr %x, ptr %y), !dbg !44
// CHECK:STDOUT: %EqWith.WithSelf.NotEqual.call = call i1 @"_CNotEqual:thunk:EqWith.f46538683c1a9318.Core:Cpp"(ptr %x, ptr %y), !dbg !45
// CHECK:STDOUT: ret void, !dbg !46
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -259,19 +259,19 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: !25 = !{i64 0, i64 4, !7}
// CHECK:STDOUT: !26 = !{!27, !27, i64 0}
// CHECK:STDOUT: !27 = !{!"bool", !9, i64 0}
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Equal", linkageName: "_CEqual:thunk:EqWith.95dfad7558f19bf5.Core:Cpp", scope: null, file: !6, line: 8, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !31)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Equal", linkageName: "_CEqual:thunk:EqWith.f46538683c1a9318.Core:Cpp", scope: null, file: !6, line: 8, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !31)
// CHECK:STDOUT: !29 = !DISubroutineType(types: !30)
// CHECK:STDOUT: !30 = !{!14, !14, !14}
// CHECK:STDOUT: !31 = !{!32, !33}
// CHECK:STDOUT: !32 = !DILocalVariable(arg: 1, scope: !28, type: !14)
// CHECK:STDOUT: !33 = !DILocalVariable(arg: 2, scope: !28, type: !14)
// CHECK:STDOUT: !34 = !DILocation(line: 8, column: 15, scope: !28)
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "NotEqual", linkageName: "_CNotEqual:thunk:EqWith.95dfad7558f19bf5.Core:Cpp", scope: null, file: !6, line: 12, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !36)
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "NotEqual", linkageName: "_CNotEqual:thunk:EqWith.f46538683c1a9318.Core:Cpp", scope: null, file: !6, line: 12, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !36)
// CHECK:STDOUT: !36 = !{!37, !38}
// CHECK:STDOUT: !37 = !DILocalVariable(arg: 1, scope: !35, type: !14)
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 2, scope: !35, type: !14)
// CHECK:STDOUT: !39 = !DILocation(line: 12, column: 15, scope: !35)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "CheckEqWith", linkageName: "_CCheckEqWith.Main.795833dfa91e6085", scope: null, file: !6, line: 18, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !41)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "CheckEqWith", linkageName: "_CCheckEqWith.Main.8514cfa07ba3e7b7", scope: null, file: !6, line: 18, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !41)
// CHECK:STDOUT: !41 = !{!42, !43}
// CHECK:STDOUT: !42 = !DILocalVariable(arg: 1, scope: !40, type: !14)
// CHECK:STDOUT: !43 = !DILocalVariable(arg: 2, scope: !40, type: !14)
@@ -298,7 +298,7 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define void @_CDriver.Main(ptr %x, ptr %y) #0 !dbg !11 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CCheckOrderedWith.Main.2434026e6d8bb659(ptr %x, ptr %y), !dbg !18
// CHECK:STDOUT: call void @_CCheckOrderedWith.Main.cf2c934aa0200133(ptr %x, ptr %y), !dbg !18
// CHECK:STDOUT: ret void, !dbg !19
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -407,7 +407,7 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define i1 @"_CLess:thunk:OrderedWith.c93a46d484590772.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !28 {
// CHECK:STDOUT: define i1 @"_CLess:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.3.temp = alloca i1, align 1, !dbg !34
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.3.temp), !dbg !34
@@ -417,7 +417,7 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define i1 @"_CLessOrEquivalent:thunk:OrderedWith.c93a46d484590772.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !35 {
// CHECK:STDOUT: define i1 @"_CLessOrEquivalent:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !35 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.3.temp = alloca i1, align 1, !dbg !39
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.3.temp), !dbg !39
@@ -427,7 +427,7 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define i1 @"_CGreater:thunk:OrderedWith.c93a46d484590772.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !40 {
// CHECK:STDOUT: define i1 @"_CGreater:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !40 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.3.temp = alloca i1, align 1, !dbg !44
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.3.temp), !dbg !44
@@ -437,7 +437,7 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define i1 @"_CGreaterOrEquivalent:thunk:OrderedWith.c93a46d484590772.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !45 {
// CHECK:STDOUT: define i1 @"_CGreaterOrEquivalent:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp"(ptr %self, ptr %other) #2 !dbg !45 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.3.temp = alloca i1, align 1, !dbg !49
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.3.temp), !dbg !49
@@ -447,12 +447,12 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr void @_CCheckOrderedWith.Main.2434026e6d8bb659(ptr %x, ptr %y) #0 !dbg !50 {
// CHECK:STDOUT: define linkonce_odr void @_CCheckOrderedWith.Main.cf2c934aa0200133(ptr %x, ptr %y) #0 !dbg !50 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %OrderedWith.WithSelf.Less.call = call i1 @"_CLess:thunk:OrderedWith.c93a46d484590772.Core:Cpp"(ptr %x, ptr %y), !dbg !54
// CHECK:STDOUT: %OrderedWith.WithSelf.Greater.call = call i1 @"_CGreater:thunk:OrderedWith.c93a46d484590772.Core:Cpp"(ptr %x, ptr %y), !dbg !55
// CHECK:STDOUT: %OrderedWith.WithSelf.LessOrEquivalent.call = call i1 @"_CLessOrEquivalent:thunk:OrderedWith.c93a46d484590772.Core:Cpp"(ptr %x, ptr %y), !dbg !56
// CHECK:STDOUT: %OrderedWith.WithSelf.GreaterOrEquivalent.call = call i1 @"_CGreaterOrEquivalent:thunk:OrderedWith.c93a46d484590772.Core:Cpp"(ptr %x, ptr %y), !dbg !57
// CHECK:STDOUT: %OrderedWith.WithSelf.Less.call = call i1 @"_CLess:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp"(ptr %x, ptr %y), !dbg !54
// CHECK:STDOUT: %OrderedWith.WithSelf.Greater.call = call i1 @"_CGreater:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp"(ptr %x, ptr %y), !dbg !55
// CHECK:STDOUT: %OrderedWith.WithSelf.LessOrEquivalent.call = call i1 @"_CLessOrEquivalent:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp"(ptr %x, ptr %y), !dbg !56
// CHECK:STDOUT: %OrderedWith.WithSelf.GreaterOrEquivalent.call = call i1 @"_CGreaterOrEquivalent:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp"(ptr %x, ptr %y), !dbg !57
// CHECK:STDOUT: ret void, !dbg !58
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -586,29 +586,29 @@ fn Driver(x: Cpp.A, y: Cpp.A) {
// CHECK:STDOUT: !25 = !{i64 0, i64 4, !7}
// CHECK:STDOUT: !26 = !{!27, !27, i64 0}
// CHECK:STDOUT: !27 = !{!"bool", !9, i64 0}
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Less", linkageName: "_CLess:thunk:OrderedWith.c93a46d484590772.Core:Cpp", scope: null, file: !6, line: 8, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !31)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Less", linkageName: "_CLess:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp", scope: null, file: !6, line: 8, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !31)
// CHECK:STDOUT: !29 = !DISubroutineType(types: !30)
// CHECK:STDOUT: !30 = !{!14, !14, !14}
// CHECK:STDOUT: !31 = !{!32, !33}
// CHECK:STDOUT: !32 = !DILocalVariable(arg: 1, scope: !28, type: !14)
// CHECK:STDOUT: !33 = !DILocalVariable(arg: 2, scope: !28, type: !14)
// CHECK:STDOUT: !34 = !DILocation(line: 8, column: 15, scope: !28)
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "LessOrEquivalent", linkageName: "_CLessOrEquivalent:thunk:OrderedWith.c93a46d484590772.Core:Cpp", scope: null, file: !6, line: 16, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !36)
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "LessOrEquivalent", linkageName: "_CLessOrEquivalent:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp", scope: null, file: !6, line: 16, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !36)
// CHECK:STDOUT: !36 = !{!37, !38}
// CHECK:STDOUT: !37 = !DILocalVariable(arg: 1, scope: !35, type: !14)
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 2, scope: !35, type: !14)
// CHECK:STDOUT: !39 = !DILocation(line: 16, column: 15, scope: !35)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "Greater", linkageName: "_CGreater:thunk:OrderedWith.c93a46d484590772.Core:Cpp", scope: null, file: !6, line: 12, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !41)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "Greater", linkageName: "_CGreater:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp", scope: null, file: !6, line: 12, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !41)
// CHECK:STDOUT: !41 = !{!42, !43}
// CHECK:STDOUT: !42 = !DILocalVariable(arg: 1, scope: !40, type: !14)
// CHECK:STDOUT: !43 = !DILocalVariable(arg: 2, scope: !40, type: !14)
// CHECK:STDOUT: !44 = !DILocation(line: 12, column: 15, scope: !40)
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "GreaterOrEquivalent", linkageName: "_CGreaterOrEquivalent:thunk:OrderedWith.c93a46d484590772.Core:Cpp", scope: null, file: !6, line: 20, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !46)
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "GreaterOrEquivalent", linkageName: "_CGreaterOrEquivalent:thunk:OrderedWith.76d9c95e44fa79ac.Core:Cpp", scope: null, file: !6, line: 20, type: !29, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !46)
// CHECK:STDOUT: !46 = !{!47, !48}
// CHECK:STDOUT: !47 = !DILocalVariable(arg: 1, scope: !45, type: !14)
// CHECK:STDOUT: !48 = !DILocalVariable(arg: 2, scope: !45, type: !14)
// CHECK:STDOUT: !49 = !DILocation(line: 20, column: 15, scope: !45)
// CHECK:STDOUT: !50 = distinct !DISubprogram(name: "CheckOrderedWith", linkageName: "_CCheckOrderedWith.Main.2434026e6d8bb659", scope: null, file: !6, line: 26, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !51)
// CHECK:STDOUT: !50 = distinct !DISubprogram(name: "CheckOrderedWith", linkageName: "_CCheckOrderedWith.Main.cf2c934aa0200133", scope: null, file: !6, line: 26, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !51)
// CHECK:STDOUT: !51 = !{!52, !53}
// CHECK:STDOUT: !52 = !DILocalVariable(arg: 1, scope: !50, type: !14)
// CHECK:STDOUT: !53 = !DILocalVariable(arg: 2, scope: !50, type: !14)
+28 -28
View File
@@ -113,10 +113,10 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
// CHECK:STDOUT:
// CHECK:STDOUT: @int_1.30e = internal constant i8 1
// CHECK:STDOUT: @int_2.305 = internal constant i16 2
// CHECK:STDOUT: @int_1.e80 = internal constant i8 1
// CHECK:STDOUT: @int_2.fb2 = internal constant i16 2
// CHECK:STDOUT: @int_1.9eb = internal constant i8 1
// CHECK:STDOUT: @int_2.470 = internal constant i16 2
// CHECK:STDOUT: @int_1.5de = internal constant i8 1
// CHECK:STDOUT: @int_2.787 = internal constant i16 2
// CHECK:STDOUT: @_Cc.Main = global i16 0
// 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:
@@ -129,14 +129,14 @@ fn PassValueExpr(y: Cpp.Y) {
// 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.30e, ptr @int_2.305, i32 3, i64 4), !dbg !18
// CHECK:STDOUT: call void @_Z11pass_signedasil.carbon_thunk.____(ptr @int_1.9eb, ptr @int_2.470, 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.e80, ptr @int_2.fb2, i32 3, i64 4), !dbg !19
// CHECK:STDOUT: call void @"_COp.ecaf8c3e76291eee:core.Destroy.Core"(ptr @int_2.fb2), !dbg !17
// CHECK:STDOUT: call void @"_COp.3de38e83520d6bec:core.Destroy.Core"(ptr @int_1.e80), !dbg !16
// CHECK:STDOUT: call void @"_COp.406738f1b62008ed:core.Destroy.Core"(ptr @int_2.305), !dbg !15
// CHECK:STDOUT: call void @"_COp.43bece552030817c:core.Destroy.Core"(ptr @int_1.30e), !dbg !14
// CHECK:STDOUT: call void @_Z13pass_unsignedhtjm.carbon_thunk.____(ptr @int_1.5de, ptr @int_2.787, i32 3, i64 4), !dbg !19
// CHECK:STDOUT: call void @"_COp.4f41a08d65e2a5a3:core.Destroy.Core"(ptr @int_2.787), !dbg !17
// CHECK:STDOUT: call void @"_COp.471bf32d53e15da8:core.Destroy.Core"(ptr @int_1.5de), !dbg !16
// CHECK:STDOUT: call void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr @int_2.470), !dbg !15
// CHECK:STDOUT: call void @"_COp.4bf3b2f84a23e67d:core.Destroy.Core"(ptr @int_1.9eb), !dbg !14
// CHECK:STDOUT: ret void, !dbg !20
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -183,25 +183,25 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.ecaf8c3e76291eee:core.Destroy.Core"(ptr %self) #0 !dbg !31 {
// CHECK:STDOUT: define weak_odr void @"_COp.4f41a08d65e2a5a3:core.Destroy.Core"(ptr %self) #0 !dbg !31 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !37
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.3de38e83520d6bec:core.Destroy.Core"(ptr %self) #0 !dbg !38 {
// CHECK:STDOUT: define weak_odr void @"_COp.471bf32d53e15da8:core.Destroy.Core"(ptr %self) #0 !dbg !38 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !44
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.406738f1b62008ed:core.Destroy.Core"(ptr %self) #0 !dbg !45 {
// CHECK:STDOUT: define weak_odr void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr %self) #0 !dbg !45 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !51
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.43bece552030817c:core.Destroy.Core"(ptr %self) #0 !dbg !52 {
// CHECK:STDOUT: define weak_odr void @"_COp.4bf3b2f84a23e67d:core.Destroy.Core"(ptr %self) #0 !dbg !52 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !58
// CHECK:STDOUT: }
@@ -230,10 +230,10 @@ fn PassValueExpr(y: Cpp.Y) {
// 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.406738f1b62008ed:core.Destroy.Core"(ptr %.loc20_28.3.temp), !dbg !69
// CHECK:STDOUT: call void @"_COp.406738f1b62008ed:core.Destroy.Core"(ptr %.loc19_18.2.temp), !dbg !68
// CHECK:STDOUT: call void @"_COp.406738f1b62008ed:core.Destroy.Core"(ptr %.loc18_18.3.temp), !dbg !67
// CHECK:STDOUT: call void @"_COp.406738f1b62008ed:core.Destroy.Core"(ptr %.loc17_18.1.temp), !dbg !66
// CHECK:STDOUT: call void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr %.loc20_28.3.temp), !dbg !69
// CHECK:STDOUT: call void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr %.loc19_18.2.temp), !dbg !68
// CHECK:STDOUT: call void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr %.loc18_18.3.temp), !dbg !67
// CHECK:STDOUT: call void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr %.loc17_18.1.temp), !dbg !66
// CHECK:STDOUT: ret void, !dbg !74
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -308,28 +308,28 @@ fn PassValueExpr(y: Cpp.Y) {
// 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.ecaf8c3e76291eee:core.Destroy.Core", scope: null, file: !6, line: 9, type: !32, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !35)
// CHECK:STDOUT: !31 = distinct !DISubprogram(name: "Op", linkageName: "_COp.4f41a08d65e2a5a3:core.Destroy.Core", scope: null, file: !6, line: 9, type: !32, spFlags: DISPFlagDefinition, unit: !5, 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.3de38e83520d6bec:core.Destroy.Core", scope: null, file: !6, line: 9, type: !39, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !42)
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "Op", linkageName: "_COp.471bf32d53e15da8:core.Destroy.Core", scope: null, file: !6, line: 9, type: !39, spFlags: DISPFlagDefinition, unit: !5, 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.406738f1b62008ed:core.Destroy.Core", scope: null, file: !6, line: 7, type: !46, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !49)
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Op", linkageName: "_COp.7b4d46d56ede77d9:core.Destroy.Core", scope: null, file: !6, line: 7, type: !46, spFlags: DISPFlagDefinition, unit: !5, 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.43bece552030817c:core.Destroy.Core", scope: null, file: !6, line: 7, type: !53, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !56)
// CHECK:STDOUT: !52 = distinct !DISubprogram(name: "Op", linkageName: "_COp.4bf3b2f84a23e67d:core.Destroy.Core", scope: null, file: !6, line: 7, type: !53, spFlags: DISPFlagDefinition, unit: !5, 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)
@@ -367,7 +367,7 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %x.var = alloca [12 x i8], align 1, !dbg !14
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %x.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.64f6b96556a8f2d4"(ptr %x.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.e5c2acf57553d2f2"(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
@@ -388,7 +388,7 @@ fn PassValueExpr(y: Cpp.Y) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Default.17a84649916546b3.Core:X.Cpp"(ptr sret([12 x i8]) %return) #2 !dbg !23 {
// CHECK:STDOUT: define void @"_COp:thunk:Default.aebeffbfb3ea6f83.Core:X.Cpp"(ptr sret([12 x i8]) %return) #2 !dbg !23 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN1XC1Ev.carbon_thunk.(ptr %return), !dbg !28
// CHECK:STDOUT: ret void, !dbg !28
@@ -416,8 +416,8 @@ 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.d288d62be0e5d791:DefaultOrUnformed.Core.64f6b96556a8f2d4"(ptr sret([12 x i8]) %return) #0 !dbg !30 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.17a84649916546b3.Core:X.Cpp"(ptr %return), !dbg !32
// CHECK:STDOUT: define linkonce_odr void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.e5c2acf57553d2f2"(ptr sret([12 x i8]) %return) #0 !dbg !30 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.aebeffbfb3ea6f83.Core:X.Cpp"(ptr %return), !dbg !32
// CHECK:STDOUT: ret void, !dbg !33
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -463,14 +463,14 @@ fn PassValueExpr(y: Cpp.Y) {
// 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.17a84649916546b3.Core:X.Cpp", scope: null, file: !24, line: 2, type: !25, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !23 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.aebeffbfb3ea6f83.Core:X.Cpp", scope: null, file: !24, line: 2, type: !25, spFlags: DISPFlagDefinition, unit: !5)
// 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.d288d62be0e5d791:DefaultOrUnformed.Core.64f6b96556a8f2d4", scope: null, file: !31, line: 9, type: !25, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !30 = distinct !DISubprogram(name: "Op", linkageName: "_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.e5c2acf57553d2f2", scope: null, file: !31, line: 9, type: !25, spFlags: DISPFlagDefinition, unit: !5)
// 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)
+59 -59
View File
@@ -218,25 +218,25 @@ fn Convert() {
// CHECK:STDOUT: define void @_CPassNonnullPtr.Main(ptr %p) #0 !dbg !18 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc22_15.2.temp = alloca ptr, align 8, !dbg !21
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.91d5ab7352c07e82"(ptr %p), !dbg !21
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.b425d6bf10aac33d"(ptr %p), !dbg !21
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc22_15.2.temp), !dbg !21
// CHECK:STDOUT: store ptr %U.as_type.as.ImplicitAs.impl.Convert.call, ptr %.loc22_15.2.temp, align 8, !dbg !21
// CHECK:STDOUT: %.loc22_15.4 = load ptr, ptr %.loc22_15.2.temp, align 8, !dbg !21
// CHECK:STDOUT: call void @_Z7TakePtrP1C(ptr %.loc22_15.4), !dbg !22
// CHECK:STDOUT: call void @"_COp.f6ed00b54444c4a3:core.Destroy.Core"(ptr %.loc22_15.2.temp), !dbg !21
// CHECK:STDOUT: call void @"_COp.129c8ad8f31c07e1:core.Destroy.Core"(ptr %.loc22_15.2.temp), !dbg !21
// CHECK:STDOUT: ret void, !dbg !23
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_Z7TakePtrP1C(ptr noundef) #1
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.52ae03024b07a1ce:core.Destroy.Core"(ptr %self) #0 !dbg !24 {
// CHECK:STDOUT: define weak_odr void @"_COp.35482251414d9bba:core.Destroy.Core"(ptr %self) #0 !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.f6ed00b54444c4a3:core.Destroy.Core"(ptr %self) #0 !dbg !28 {
// CHECK:STDOUT: define weak_odr void @"_COp.129c8ad8f31c07e1:core.Destroy.Core"(ptr %self) #0 !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !31
// CHECK:STDOUT: }
@@ -260,12 +260,12 @@ fn Convert() {
// CHECK:STDOUT: define void @_CPassNonnullPtrWithThunk.Main(ptr %p) #0 !dbg !41 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc35_24.2.temp = alloca ptr, align 8, !dbg !44
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.91d5ab7352c07e82"(ptr %p), !dbg !44
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.b425d6bf10aac33d"(ptr %p), !dbg !44
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc35_24.2.temp), !dbg !44
// CHECK:STDOUT: store ptr %U.as_type.as.ImplicitAs.impl.Convert.call, ptr %.loc35_24.2.temp, align 8, !dbg !44
// CHECK:STDOUT: %.loc35_24.4 = load ptr, ptr %.loc35_24.2.temp, align 8, !dbg !44
// CHECK:STDOUT: call void @_Z16TakePtrWithThunkP1Ci.carbon_thunk._(ptr %.loc35_24.4), !dbg !45
// CHECK:STDOUT: call void @"_COp.f6ed00b54444c4a3:core.Destroy.Core"(ptr %.loc35_24.2.temp), !dbg !44
// CHECK:STDOUT: call void @"_COp.129c8ad8f31c07e1:core.Destroy.Core"(ptr %.loc35_24.2.temp), !dbg !44
// CHECK:STDOUT: ret void, !dbg !46
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -294,8 +294,8 @@ fn Convert() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.91d5ab7352c07e82"(ptr %self) #0 !dbg !53 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.a15aada625dab765:OptionalAs.0e326e799dad0c64.Core.94c82337d7d14d1e"(ptr %self), !dbg !59
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.b425d6bf10aac33d"(ptr %self) #0 !dbg !53 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.ba9a17e320476215:OptionalAs.7eef99cd03a74de4.Core.3dfa3b552b212aa8"(ptr %self), !dbg !59
// CHECK:STDOUT: ret ptr %1, !dbg !60
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -303,25 +303,25 @@ fn Convert() {
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #3
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.a15aada625dab765:OptionalAs.0e326e799dad0c64.Core.94c82337d7d14d1e"(ptr %self) #0 !dbg !61 {
// CHECK:STDOUT: %1 = call ptr @_CSome.Optional.Core.94c82337d7d14d1e(ptr %self), !dbg !64
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.ba9a17e320476215:OptionalAs.7eef99cd03a74de4.Core.3dfa3b552b212aa8"(ptr %self) #0 !dbg !61 {
// CHECK:STDOUT: %1 = call ptr @_CSome.Optional.Core.3dfa3b552b212aa8(ptr %self), !dbg !64
// CHECK:STDOUT: ret ptr %1, !dbg !65
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @_CSome.Optional.Core.94c82337d7d14d1e(ptr %value) #0 !dbg !66 {
// CHECK:STDOUT: %1 = call ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655"(ptr %value), !dbg !69
// CHECK:STDOUT: define linkonce_odr ptr @_CSome.Optional.Core.3dfa3b552b212aa8(ptr %value) #0 !dbg !66 {
// CHECK:STDOUT: %1 = call ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690"(ptr %value), !dbg !69
// CHECK:STDOUT: ret ptr %1, !dbg !70
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655"(ptr %self) #0 !dbg !71 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690"(ptr %self) #0 !dbg !71 {
// CHECK:STDOUT: %1 = alloca ptr, align 8, !dbg !74
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %1), !dbg !74
// CHECK:STDOUT: store ptr poison, ptr %1, align 8, !dbg !74
// CHECK:STDOUT: store ptr %self, ptr %1, align 8, !dbg !75
// CHECK:STDOUT: %2 = load ptr, ptr %1, align 8, !dbg !76
// CHECK:STDOUT: call void @"_COp.52ae03024b07a1ce:core.Destroy.Core"(ptr %1), !dbg !74
// CHECK:STDOUT: call void @"_COp.35482251414d9bba:core.Destroy.Core"(ptr %1), !dbg !74
// CHECK:STDOUT: ret ptr %2, !dbg !77
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -330,7 +330,7 @@ fn Convert() {
// CHECK:STDOUT: declare noundef ptr @_Z18ReturnPtrWithThunki(i32 noundef) #1
// CHECK:STDOUT:
// CHECK:STDOUT: ; uselistorder directives
// CHECK:STDOUT: uselistorder ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.91d5ab7352c07e82", { 1, 0 }
// CHECK:STDOUT: uselistorder ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.b425d6bf10aac33d", { 1, 0 }
// CHECK:STDOUT: uselistorder ptr @llvm.lifetime.start.p0, { 0, 2, 1 }
// CHECK:STDOUT:
// CHECK:STDOUT: attributes #0 = { nounwind }
@@ -366,11 +366,11 @@ fn Convert() {
// CHECK:STDOUT: !21 = !DILocation(line: 22, column: 15, scope: !18)
// CHECK:STDOUT: !22 = !DILocation(line: 22, column: 3, scope: !18)
// CHECK:STDOUT: !23 = !DILocation(line: 19, column: 1, scope: !18)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Op", linkageName: "_COp.52ae03024b07a1ce:core.Destroy.Core", scope: null, file: !6, line: 22, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !25)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Op", linkageName: "_COp.35482251414d9bba:core.Destroy.Core", scope: null, file: !6, line: 22, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !25)
// CHECK:STDOUT: !25 = !{!26}
// CHECK:STDOUT: !26 = !DILocalVariable(arg: 1, scope: !24, type: !14)
// CHECK:STDOUT: !27 = !DILocation(line: 22, column: 15, scope: !24)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Op", linkageName: "_COp.f6ed00b54444c4a3:core.Destroy.Core", scope: null, file: !6, line: 22, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Op", linkageName: "_COp.129c8ad8f31c07e1:core.Destroy.Core", scope: null, file: !6, line: 22, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !29 = !{!30}
// CHECK:STDOUT: !30 = !DILocalVariable(arg: 1, scope: !28, type: !14)
// CHECK:STDOUT: !31 = !DILocation(line: 22, column: 15, scope: !28)
@@ -395,7 +395,7 @@ fn Convert() {
// CHECK:STDOUT: !50 = distinct !DISubprogram(name: "ReturnPtrWithThunk", linkageName: "_CReturnPtrWithThunk.Main", scope: null, file: !6, line: 38, type: !33, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !51 = !DILocation(line: 39, column: 10, scope: !50)
// CHECK:STDOUT: !52 = !DILocation(line: 39, column: 3, scope: !50)
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.91d5ab7352c07e82", scope: null, file: !54, line: 96, type: !55, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !57)
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.b425d6bf10aac33d", scope: null, file: !54, line: 96, type: !55, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !57)
// CHECK:STDOUT: !54 = !DIFile(filename: "{{.*}}/prelude/types/optional.carbon", directory: "")
// CHECK:STDOUT: !55 = !DISubroutineType(types: !56)
// CHECK:STDOUT: !56 = !{!14, !14}
@@ -403,17 +403,17 @@ fn Convert() {
// CHECK:STDOUT: !58 = !DILocalVariable(arg: 1, scope: !53, type: !14)
// CHECK:STDOUT: !59 = !DILocation(line: 97, column: 12, scope: !53)
// CHECK:STDOUT: !60 = !DILocation(line: 97, column: 5, scope: !53)
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.a15aada625dab765:OptionalAs.0e326e799dad0c64.Core.94c82337d7d14d1e", scope: null, file: !54, line: 71, type: !55, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !62)
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.ba9a17e320476215:OptionalAs.7eef99cd03a74de4.Core.3dfa3b552b212aa8", scope: null, file: !54, line: 71, type: !55, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !62)
// CHECK:STDOUT: !62 = !{!63}
// CHECK:STDOUT: !63 = !DILocalVariable(arg: 1, scope: !61, type: !14)
// CHECK:STDOUT: !64 = !DILocation(line: 72, column: 12, scope: !61)
// CHECK:STDOUT: !65 = !DILocation(line: 72, column: 5, scope: !61)
// CHECK:STDOUT: !66 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.94c82337d7d14d1e", scope: null, file: !54, line: 30, type: !55, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !67)
// CHECK:STDOUT: !66 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.3dfa3b552b212aa8", scope: null, file: !54, line: 30, type: !55, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !67)
// CHECK:STDOUT: !67 = !{!68}
// CHECK:STDOUT: !68 = !DILocalVariable(arg: 1, scope: !66, type: !14)
// CHECK:STDOUT: !69 = !DILocation(line: 31, column: 12, scope: !66)
// CHECK:STDOUT: !70 = !DILocation(line: 31, column: 5, scope: !66)
// CHECK:STDOUT: !71 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655", scope: null, file: !54, line: 150, type: !55, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !72)
// CHECK:STDOUT: !71 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690", scope: null, file: !54, line: 150, type: !55, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !72)
// CHECK:STDOUT: !72 = !{!73}
// CHECK:STDOUT: !73 = !DILocalVariable(arg: 1, scope: !71, type: !14)
// CHECK:STDOUT: !74 = !DILocation(line: 151, column: 14, scope: !71)
@@ -434,13 +434,13 @@ fn Convert() {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc9_21.1.temp), !dbg !14
// CHECK:STDOUT: store ptr %make.call, ptr %.loc9_21.1.temp, align 8, !dbg !14
// CHECK:STDOUT: %.loc9_21.3 = load ptr, ptr %.loc9_21.1.temp, align 8, !dbg !14
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.213b41258a60ff52"(ptr %.loc9_21.3), !dbg !14
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.8c78338db8262399"(ptr %.loc9_21.3), !dbg !14
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc9_21.5.temp), !dbg !14
// CHECK:STDOUT: store ptr %U.as_type.as.ImplicitAs.impl.Convert.call, ptr %.loc9_21.5.temp, align 8, !dbg !14
// CHECK:STDOUT: %.loc9_21.7 = load ptr, ptr %.loc9_21.5.temp, align 8, !dbg !14
// CHECK:STDOUT: call void @_Z4takePK1C(ptr %.loc9_21.7), !dbg !15
// CHECK:STDOUT: call void @"_COp.df75a80449161262:core.Destroy.Core"(ptr %.loc9_21.5.temp), !dbg !14
// CHECK:STDOUT: call void @"_COp.1cafd18779d19acf:core.Destroy.Core"(ptr %.loc9_21.1.temp), !dbg !14
// CHECK:STDOUT: call void @"_COp.ce10e9f6ae2a5326:core.Destroy.Core"(ptr %.loc9_21.5.temp), !dbg !14
// CHECK:STDOUT: call void @"_COp.02e5976f4da6b54a:core.Destroy.Core"(ptr %.loc9_21.1.temp), !dbg !14
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -449,25 +449,25 @@ fn Convert() {
// CHECK:STDOUT: declare void @_Z4takePK1C(ptr noundef) #1
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.e036a220112b6940:core.Destroy.Core"(ptr %self) #0 !dbg !17 {
// CHECK:STDOUT: define weak_odr void @"_COp.3c6e3be6b375f0fe:core.Destroy.Core"(ptr %self) #0 !dbg !17 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !23
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.df75a80449161262:core.Destroy.Core"(ptr %self) #0 !dbg !24 {
// CHECK:STDOUT: define weak_odr void @"_COp.ce10e9f6ae2a5326:core.Destroy.Core"(ptr %self) #0 !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.52ae03024b07a1ce:core.Destroy.Core"(ptr %self) #0 !dbg !28 {
// CHECK:STDOUT: define weak_odr void @"_COp.35482251414d9bba:core.Destroy.Core"(ptr %self) #0 !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !31
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.1cafd18779d19acf:core.Destroy.Core"(ptr %self) #0 !dbg !32 {
// CHECK:STDOUT: define weak_odr void @"_COp.02e5976f4da6b54a:core.Destroy.Core"(ptr %self) #0 !dbg !32 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !35
// CHECK:STDOUT: }
@@ -476,77 +476,77 @@ fn Convert() {
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #2
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.213b41258a60ff52"(ptr %self) #0 !dbg !36 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.Optional.379070d241187444.Core:OptionalAs.f58b2ba767714873.Core.b52a3e635fe8ef33"(ptr %self), !dbg !42
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.8c78338db8262399"(ptr %self) #0 !dbg !36 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.Optional.5dca1548b0a7c023.Core:OptionalAs.f5e7d4305ac1f327.Core.393d60e97ff65cbb"(ptr %self), !dbg !42
// CHECK:STDOUT: ret ptr %1, !dbg !43
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.Optional.379070d241187444.Core:OptionalAs.f58b2ba767714873.Core.b52a3e635fe8ef33"(ptr %self) #0 !dbg !44 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.Optional.5dca1548b0a7c023.Core:OptionalAs.f5e7d4305ac1f327.Core.393d60e97ff65cbb"(ptr %self) #0 !dbg !44 {
// CHECK:STDOUT: %temp = alloca ptr, align 8, !dbg !47
// CHECK:STDOUT: %temp1 = alloca ptr, align 8, !dbg !47
// CHECK:STDOUT: %1 = call i1 @_CHasValue.Optional.Core.12123c0db49c1ff8(ptr %self), !dbg !48
// CHECK:STDOUT: %1 = call i1 @_CHasValue.Optional.Core.63099895f5fdc5b3(ptr %self), !dbg !48
// CHECK:STDOUT: br i1 %1, label %2, label %7, !dbg !49
// CHECK:STDOUT:
// CHECK:STDOUT: 2: ; preds = %0
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %temp), !dbg !47
// CHECK:STDOUT: %3 = call ptr @_CGet.Optional.Core.12123c0db49c1ff8(ptr %self), !dbg !47
// CHECK:STDOUT: %3 = call ptr @_CGet.Optional.Core.63099895f5fdc5b3(ptr %self), !dbg !47
// CHECK:STDOUT: store ptr %3, ptr %temp, align 8, !dbg !47
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %temp1), !dbg !47
// CHECK:STDOUT: %4 = load ptr, ptr %temp, align 8, !dbg !47
// CHECK:STDOUT: store ptr %4, ptr %temp1, align 8, !dbg !47
// CHECK:STDOUT: %5 = load ptr, ptr %temp1, align 8, !dbg !47
// CHECK:STDOUT: %6 = call ptr @_CSome.Optional.Core.5f67a2f4ff57bdfc(ptr %5), !dbg !50
// CHECK:STDOUT: %6 = call ptr @_CSome.Optional.Core.24cf9e6f9173c4f1(ptr %5), !dbg !50
// CHECK:STDOUT: ret ptr %6, !dbg !51
// CHECK:STDOUT:
// CHECK:STDOUT: 7: ; preds = %0
// CHECK:STDOUT: %8 = call ptr @_CNone.Optional.Core.5f67a2f4ff57bdfc(), !dbg !52
// CHECK:STDOUT: %8 = call ptr @_CNone.Optional.Core.24cf9e6f9173c4f1(), !dbg !52
// CHECK:STDOUT: ret ptr %8, !dbg !53
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr i1 @_CHasValue.Optional.Core.12123c0db49c1ff8(ptr %self) #0 !dbg !54 {
// CHECK:STDOUT: %1 = call i1 @"_CHas.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655"(ptr %self), !dbg !57
// CHECK:STDOUT: define linkonce_odr i1 @_CHasValue.Optional.Core.63099895f5fdc5b3(ptr %self) #0 !dbg !54 {
// CHECK:STDOUT: %1 = call i1 @"_CHas.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690"(ptr %self), !dbg !57
// CHECK:STDOUT: ret i1 %1, !dbg !58
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @_CGet.Optional.Core.12123c0db49c1ff8(ptr %self) #0 !dbg !59 {
// CHECK:STDOUT: %1 = call ptr @"_CGet.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655"(ptr %self), !dbg !62
// CHECK:STDOUT: define linkonce_odr ptr @_CGet.Optional.Core.63099895f5fdc5b3(ptr %self) #0 !dbg !59 {
// CHECK:STDOUT: %1 = call ptr @"_CGet.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690"(ptr %self), !dbg !62
// CHECK:STDOUT: ret ptr %1, !dbg !63
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @_CSome.Optional.Core.5f67a2f4ff57bdfc(ptr %value) #0 !dbg !64 {
// CHECK:STDOUT: %1 = call ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.27e79123988f1998"(ptr %value), !dbg !67
// CHECK:STDOUT: define linkonce_odr ptr @_CSome.Optional.Core.24cf9e6f9173c4f1(ptr %value) #0 !dbg !64 {
// CHECK:STDOUT: %1 = call ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.11944b9073985c4a"(ptr %value), !dbg !67
// CHECK:STDOUT: ret ptr %1, !dbg !68
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @_CNone.Optional.Core.5f67a2f4ff57bdfc() #0 !dbg !69 {
// CHECK:STDOUT: define linkonce_odr ptr @_CNone.Optional.Core.24cf9e6f9173c4f1() #0 !dbg !69 {
// CHECK:STDOUT: ret ptr null, !dbg !72
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr i1 @"_CHas.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655"(ptr %value) #0 !dbg !73 {
// CHECK:STDOUT: define linkonce_odr i1 @"_CHas.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690"(ptr %value) #0 !dbg !73 {
// CHECK:STDOUT: %1 = icmp eq ptr %value, null, !dbg !76
// CHECK:STDOUT: %2 = xor i1 %1, true, !dbg !77
// CHECK:STDOUT: ret i1 %2, !dbg !78
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CGet.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655"(ptr %value) #0 !dbg !79 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CGet.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690"(ptr %value) #0 !dbg !79 {
// CHECK:STDOUT: ret ptr %value, !dbg !82
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.27e79123988f1998"(ptr %self) #0 !dbg !83 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.11944b9073985c4a"(ptr %self) #0 !dbg !83 {
// CHECK:STDOUT: %1 = alloca ptr, align 8, !dbg !86
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %1), !dbg !86
// CHECK:STDOUT: store ptr poison, ptr %1, align 8, !dbg !86
// CHECK:STDOUT: store ptr %self, ptr %1, align 8, !dbg !87
// CHECK:STDOUT: %2 = load ptr, ptr %1, align 8, !dbg !88
// CHECK:STDOUT: call void @"_COp.e036a220112b6940:core.Destroy.Core"(ptr %1), !dbg !86
// CHECK:STDOUT: call void @"_COp.3c6e3be6b375f0fe:core.Destroy.Core"(ptr %1), !dbg !86
// CHECK:STDOUT: ret ptr %2, !dbg !89
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -578,26 +578,26 @@ fn Convert() {
// CHECK:STDOUT: !14 = !DILocation(line: 9, column: 12, scope: !11)
// CHECK:STDOUT: !15 = !DILocation(line: 9, column: 3, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 8, column: 1, scope: !11)
// CHECK:STDOUT: !17 = distinct !DISubprogram(name: "Op", linkageName: "_COp.e036a220112b6940:core.Destroy.Core", scope: null, file: !6, line: 9, type: !18, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !21)
// CHECK:STDOUT: !17 = distinct !DISubprogram(name: "Op", linkageName: "_COp.3c6e3be6b375f0fe:core.Destroy.Core", scope: null, file: !6, line: 9, type: !18, spFlags: DISPFlagDefinition, unit: !5, 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: 9, column: 12, scope: !17)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Op", linkageName: "_COp.df75a80449161262:core.Destroy.Core", scope: null, file: !6, line: 9, type: !18, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !25)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Op", linkageName: "_COp.ce10e9f6ae2a5326:core.Destroy.Core", scope: null, file: !6, line: 9, type: !18, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !25)
// CHECK:STDOUT: !25 = !{!26}
// CHECK:STDOUT: !26 = !DILocalVariable(arg: 1, scope: !24, type: !20)
// CHECK:STDOUT: !27 = !DILocation(line: 9, column: 12, scope: !24)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Op", linkageName: "_COp.52ae03024b07a1ce:core.Destroy.Core", scope: null, file: !6, line: 9, type: !18, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "Op", linkageName: "_COp.35482251414d9bba:core.Destroy.Core", scope: null, file: !6, line: 9, type: !18, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !29 = !{!30}
// CHECK:STDOUT: !30 = !DILocalVariable(arg: 1, scope: !28, type: !20)
// CHECK:STDOUT: !31 = !DILocation(line: 9, column: 12, scope: !28)
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1cafd18779d19acf:core.Destroy.Core", scope: null, file: !6, line: 9, type: !18, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !33)
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "Op", linkageName: "_COp.02e5976f4da6b54a:core.Destroy.Core", scope: null, file: !6, line: 9, type: !18, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !33)
// CHECK:STDOUT: !33 = !{!34}
// CHECK:STDOUT: !34 = !DILocalVariable(arg: 1, scope: !32, type: !20)
// CHECK:STDOUT: !35 = !DILocation(line: 9, column: 12, scope: !32)
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.213b41258a60ff52", scope: null, file: !37, line: 96, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !40)
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.8c78338db8262399", scope: null, file: !37, line: 96, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !40)
// CHECK:STDOUT: !37 = !DIFile(filename: "{{.*}}/prelude/types/optional.carbon", directory: "")
// CHECK:STDOUT: !38 = !DISubroutineType(types: !39)
// CHECK:STDOUT: !39 = !{!20, !20}
@@ -605,7 +605,7 @@ fn Convert() {
// CHECK:STDOUT: !41 = !DILocalVariable(arg: 1, scope: !36, type: !20)
// CHECK:STDOUT: !42 = !DILocation(line: 97, column: 12, scope: !36)
// CHECK:STDOUT: !43 = !DILocation(line: 97, column: 5, scope: !36)
// CHECK:STDOUT: !44 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.Optional.379070d241187444.Core:OptionalAs.f58b2ba767714873.Core.b52a3e635fe8ef33", scope: null, file: !37, line: 86, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !45)
// CHECK:STDOUT: !44 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.Optional.5dca1548b0a7c023.Core:OptionalAs.f5e7d4305ac1f327.Core.393d60e97ff65cbb", scope: null, file: !37, line: 86, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !45)
// CHECK:STDOUT: !45 = !{!46}
// CHECK:STDOUT: !46 = !DILocalVariable(arg: 1, scope: !44, type: !20)
// CHECK:STDOUT: !47 = !DILocation(line: 88, column: 31, scope: !44)
@@ -615,36 +615,36 @@ fn Convert() {
// CHECK:STDOUT: !51 = !DILocation(line: 88, column: 7, scope: !44)
// CHECK:STDOUT: !52 = !DILocation(line: 90, column: 12, scope: !44)
// CHECK:STDOUT: !53 = !DILocation(line: 90, column: 5, scope: !44)
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "HasValue", linkageName: "_CHasValue.Optional.Core.12123c0db49c1ff8", scope: null, file: !37, line: 33, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !55)
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "HasValue", linkageName: "_CHasValue.Optional.Core.63099895f5fdc5b3", scope: null, file: !37, line: 33, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !55)
// CHECK:STDOUT: !55 = !{!56}
// CHECK:STDOUT: !56 = !DILocalVariable(arg: 1, scope: !54, type: !20)
// CHECK:STDOUT: !57 = !DILocation(line: 34, column: 12, scope: !54)
// CHECK:STDOUT: !58 = !DILocation(line: 34, column: 5, scope: !54)
// CHECK:STDOUT: !59 = distinct !DISubprogram(name: "Get", linkageName: "_CGet.Optional.Core.12123c0db49c1ff8", scope: null, file: !37, line: 36, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !60)
// CHECK:STDOUT: !59 = distinct !DISubprogram(name: "Get", linkageName: "_CGet.Optional.Core.63099895f5fdc5b3", scope: null, file: !37, line: 36, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !60)
// CHECK:STDOUT: !60 = !{!61}
// CHECK:STDOUT: !61 = !DILocalVariable(arg: 1, scope: !59, type: !20)
// CHECK:STDOUT: !62 = !DILocation(line: 37, column: 12, scope: !59)
// CHECK:STDOUT: !63 = !DILocation(line: 37, column: 5, scope: !59)
// CHECK:STDOUT: !64 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.5f67a2f4ff57bdfc", scope: null, file: !37, line: 30, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !65)
// CHECK:STDOUT: !64 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.24cf9e6f9173c4f1", scope: null, file: !37, line: 30, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !65)
// CHECK:STDOUT: !65 = !{!66}
// CHECK:STDOUT: !66 = !DILocalVariable(arg: 1, scope: !64, type: !20)
// CHECK:STDOUT: !67 = !DILocation(line: 31, column: 12, scope: !64)
// CHECK:STDOUT: !68 = !DILocation(line: 31, column: 5, scope: !64)
// CHECK:STDOUT: !69 = distinct !DISubprogram(name: "None", linkageName: "_CNone.Optional.Core.5f67a2f4ff57bdfc", scope: null, file: !37, line: 27, type: !70, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !69 = distinct !DISubprogram(name: "None", linkageName: "_CNone.Optional.Core.24cf9e6f9173c4f1", scope: null, file: !37, line: 27, type: !70, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !70 = !DISubroutineType(types: !71)
// CHECK:STDOUT: !71 = !{!20}
// CHECK:STDOUT: !72 = !DILocation(line: 28, column: 5, scope: !69)
// CHECK:STDOUT: !73 = distinct !DISubprogram(name: "Has", linkageName: "_CHas.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655", scope: null, file: !37, line: 156, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !74)
// CHECK:STDOUT: !73 = distinct !DISubprogram(name: "Has", linkageName: "_CHas.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690", scope: null, file: !37, line: 156, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !74)
// CHECK:STDOUT: !74 = !{!75}
// CHECK:STDOUT: !75 = !DILocalVariable(arg: 1, scope: !73, type: !20)
// CHECK:STDOUT: !76 = !DILocation(line: 157, column: 16, scope: !73)
// CHECK:STDOUT: !77 = !DILocation(line: 157, column: 12, scope: !73)
// CHECK:STDOUT: !78 = !DILocation(line: 157, column: 5, scope: !73)
// CHECK:STDOUT: !79 = distinct !DISubprogram(name: "Get", linkageName: "_CGet.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655", scope: null, file: !37, line: 159, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !80)
// CHECK:STDOUT: !79 = distinct !DISubprogram(name: "Get", linkageName: "_CGet.e8f8f92d3d08d149:OptionalStorage.Core.908e8f868f225690", scope: null, file: !37, line: 159, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !80)
// CHECK:STDOUT: !80 = !{!81}
// CHECK:STDOUT: !81 = !DILocalVariable(arg: 1, scope: !79, type: !20)
// CHECK:STDOUT: !82 = !DILocation(line: 160, column: 5, scope: !79)
// CHECK:STDOUT: !83 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.27e79123988f1998", scope: null, file: !37, line: 150, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !84)
// CHECK:STDOUT: !83 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.11944b9073985c4a", scope: null, file: !37, line: 150, type: !38, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !84)
// CHECK:STDOUT: !84 = !{!85}
// CHECK:STDOUT: !85 = !DILocalVariable(arg: 1, scope: !83, type: !20)
// CHECK:STDOUT: !86 = !DILocation(line: 151, column: 14, scope: !83)
+24 -24
View File
@@ -144,7 +144,7 @@ fn GetRefs() {
// CHECK:STDOUT: %_.var.2 = alloca i32, align 4, !dbg !17
// CHECK:STDOUT: %.loc25_23.2.temp = alloca i32, align 4, !dbg !18
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %c.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b"(ptr %c.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca"(ptr %c.var), !dbg !14
// CHECK:STDOUT: call void @_Z8TakeCRefR1C(ptr %c.var), !dbg !19
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %_.var.1), !dbg !15
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 1 %_.var.1, ptr align 1 @C.val.loc19_20, i64 0, i1 false), !dbg !15
@@ -160,9 +160,9 @@ fn GetRefs() {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc25_23.2.temp), !dbg !18
// CHECK:STDOUT: store i32 %.loc25_23.1, ptr %.loc25_23.2.temp, align 4, !dbg !18
// CHECK:STDOUT: call void @_Z15TakeConstIntRefRKi.carbon_thunk._(ptr %.loc25_23.2.temp), !dbg !24
// CHECK:STDOUT: call void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %.loc25_23.2.temp), !dbg !18
// CHECK:STDOUT: call void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %_.var.2), !dbg !17
// CHECK:STDOUT: call void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %n.var), !dbg !16
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %.loc25_23.2.temp), !dbg !18
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %_.var.2), !dbg !17
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %n.var), !dbg !16
// CHECK:STDOUT: ret void, !dbg !25
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -176,7 +176,7 @@ fn GetRefs() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp"(ptr sret({}) %return) #2 !dbg !29 {
// CHECK:STDOUT: define void @"_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp"(ptr sret({}) %return) #2 !dbg !29 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN1CC1Ev.carbon_thunk.(ptr %return), !dbg !33
// CHECK:STDOUT: ret void, !dbg !33
@@ -227,7 +227,7 @@ fn GetRefs() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #0 !dbg !36 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #0 !dbg !36 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !42
// CHECK:STDOUT: }
@@ -236,8 +236,8 @@ fn GetRefs() {
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #5
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b"(ptr sret({}) %return) #0 !dbg !43 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp"(ptr %return), !dbg !45
// CHECK:STDOUT: define linkonce_odr void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca"(ptr sret({}) %return) #0 !dbg !43 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp"(ptr %return), !dbg !45
// CHECK:STDOUT: ret void, !dbg !46
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -253,7 +253,7 @@ fn GetRefs() {
// CHECK:STDOUT: declare void @_Z15TakeConstIntRefRKi(ptr noundef nonnull align 4 dereferenceable(4)) #3
// CHECK:STDOUT:
// CHECK:STDOUT: ; uselistorder directives
// CHECK:STDOUT: uselistorder ptr @"_COp.7e389eab4a7e5487:core.Destroy.Core", { 2, 1, 0 }
// CHECK:STDOUT: uselistorder ptr @"_COp.94e3ca86614aba5d:core.Destroy.Core", { 2, 1, 0 }
// CHECK:STDOUT: uselistorder ptr @llvm.lifetime.start.p0, { 4, 3, 2, 1, 0 }
// CHECK:STDOUT:
// CHECK:STDOUT: attributes #0 = { nounwind }
@@ -296,21 +296,21 @@ fn GetRefs() {
// CHECK:STDOUT: !26 = !{!27, !27, i64 0}
// CHECK:STDOUT: !27 = !{!"p1 _ZTS1C", !28, i64 0}
// CHECK:STDOUT: !28 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp", scope: null, file: !6, line: 5, type: !30, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp", scope: null, file: !6, line: 5, type: !30, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !30 = !DISubroutineType(types: !31)
// CHECK:STDOUT: !31 = !{!32}
// CHECK:STDOUT: !32 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
// CHECK:STDOUT: !33 = !DILocation(line: 5, column: 7, scope: !29)
// CHECK:STDOUT: !34 = !{!35, !35, i64 0}
// CHECK:STDOUT: !35 = !{!"p1 int", !28, i64 0}
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "Op", linkageName: "_COp.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 25, type: !37, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !40)
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 25, type: !37, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !40)
// CHECK:STDOUT: !37 = !DISubroutineType(types: !38)
// CHECK:STDOUT: !38 = !{null, !39}
// CHECK:STDOUT: !39 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !40 = !{!41}
// CHECK:STDOUT: !41 = !DILocalVariable(arg: 1, scope: !36, type: !39)
// CHECK:STDOUT: !42 = !DILocation(line: 25, column: 23, scope: !36)
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "Op", linkageName: "_COp.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b", scope: null, file: !44, line: 9, type: !30, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "Op", linkageName: "_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca", scope: null, file: !44, line: 9, type: !30, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !44 = !DIFile(filename: "min_prelude/parts/default.carbon", directory: "")
// CHECK:STDOUT: !45 = !DILocation(line: 9, column: 28, scope: !43)
// CHECK:STDOUT: !46 = !DILocation(line: 9, column: 21, scope: !43)
@@ -333,7 +333,7 @@ fn GetRefs() {
// CHECK:STDOUT: %_.var = alloca i32, align 4, !dbg !17
// CHECK:STDOUT: %.loc26_23.2.temp = alloca i32, align 4, !dbg !18
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %c.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b"(ptr %c.var), !dbg !14
// CHECK:STDOUT: call void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca"(ptr %c.var), !dbg !14
// CHECK:STDOUT: call void @_Z8TakeCRefR1C10ForceThunk.carbon_thunk.r(ptr %c.var), !dbg !19
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc20_18.2.temp), !dbg !15
// CHECK:STDOUT: call void @_Z9TakeCRRefRK1C10ForceThunk.carbon_thunk._(ptr @C.val.loc20_20.3), !dbg !20
@@ -348,9 +348,9 @@ fn GetRefs() {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc26_23.2.temp), !dbg !18
// CHECK:STDOUT: store i32 %.loc26_23.1, ptr %.loc26_23.2.temp, align 4, !dbg !18
// CHECK:STDOUT: call void @_Z15TakeConstIntRefRKi10ForceThunk.carbon_thunk._(ptr %.loc26_23.2.temp), !dbg !24
// CHECK:STDOUT: call void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %.loc26_23.2.temp), !dbg !18
// CHECK:STDOUT: call void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %_.var), !dbg !17
// CHECK:STDOUT: call void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %n.var), !dbg !16
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %.loc26_23.2.temp), !dbg !18
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %_.var), !dbg !17
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %n.var), !dbg !16
// CHECK:STDOUT: ret void, !dbg !25
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -364,7 +364,7 @@ fn GetRefs() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp"(ptr sret({}) %return) #2 !dbg !29 {
// CHECK:STDOUT: define void @"_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp"(ptr sret({}) %return) #2 !dbg !29 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN1CC1Ev.carbon_thunk.(ptr %return), !dbg !33
// CHECK:STDOUT: ret void, !dbg !33
@@ -437,7 +437,7 @@ fn GetRefs() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #0 !dbg !38 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #0 !dbg !38 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !44
// CHECK:STDOUT: }
@@ -446,8 +446,8 @@ fn GetRefs() {
// 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.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b"(ptr sret({}) %return) #0 !dbg !45 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp"(ptr %return), !dbg !47
// CHECK:STDOUT: define linkonce_odr void @"_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca"(ptr sret({}) %return) #0 !dbg !45 {
// CHECK:STDOUT: call void @"_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp"(ptr %return), !dbg !47
// CHECK:STDOUT: ret void, !dbg !48
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -464,7 +464,7 @@ fn GetRefs() {
// CHECK:STDOUT: declare void @_Z15TakeConstIntRefRKi10ForceThunk(ptr noundef nonnull align 4 dereferenceable(4)) #5
// CHECK:STDOUT:
// CHECK:STDOUT: ; uselistorder directives
// CHECK:STDOUT: uselistorder ptr @"_COp.7e389eab4a7e5487:core.Destroy.Core", { 2, 1, 0 }
// CHECK:STDOUT: uselistorder ptr @"_COp.94e3ca86614aba5d:core.Destroy.Core", { 2, 1, 0 }
// CHECK:STDOUT: uselistorder ptr @llvm.lifetime.start.p0, { 4, 3, 2, 1, 0 }
// CHECK:STDOUT:
// CHECK:STDOUT: attributes #0 = { nounwind }
@@ -507,7 +507,7 @@ fn GetRefs() {
// CHECK:STDOUT: !26 = !{!27, !27, i64 0}
// CHECK:STDOUT: !27 = !{!"p1 _ZTS1C", !28, i64 0}
// CHECK:STDOUT: !28 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.7b1e6a57c714cdb7.Core:C.Cpp", scope: null, file: !6, line: 5, type: !30, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Default.5648bcc2d6c775b7.Core:C.Cpp", scope: null, file: !6, line: 5, type: !30, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !30 = !DISubroutineType(types: !31)
// CHECK:STDOUT: !31 = !{!32}
// CHECK:STDOUT: !32 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
@@ -516,14 +516,14 @@ fn GetRefs() {
// CHECK:STDOUT: !35 = !{!36, !36, i64 0}
// CHECK:STDOUT: !36 = !{!"p1 int", !28, i64 0}
// CHECK:STDOUT: !37 = !{i64 4}
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "Op", linkageName: "_COp.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 26, type: !39, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !42)
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 26, type: !39, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !42)
// CHECK:STDOUT: !39 = !DISubroutineType(types: !40)
// CHECK:STDOUT: !40 = !{null, !41}
// CHECK:STDOUT: !41 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !42 = !{!43}
// CHECK:STDOUT: !43 = !DILocalVariable(arg: 1, scope: !38, type: !41)
// CHECK:STDOUT: !44 = !DILocation(line: 26, column: 23, scope: !38)
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Op", linkageName: "_COp.d288d62be0e5d791:DefaultOrUnformed.Core.93349b0fe912a29b", scope: null, file: !46, line: 9, type: !30, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Op", linkageName: "_COp.cbe5dd53b28eb3d1:DefaultOrUnformed.Core.2603c91dd66a1dca", scope: null, file: !46, line: 9, type: !30, spFlags: DISPFlagDefinition, unit: !5)
// CHECK:STDOUT: !46 = !DIFile(filename: "min_prelude/parts/default.carbon", directory: "")
// CHECK:STDOUT: !47 = !DILocation(line: 9, column: 28, scope: !45)
// CHECK:STDOUT: !48 = !DILocation(line: 9, column: 21, scope: !45)
+28 -28
View File
@@ -263,33 +263,33 @@ fn Call(x: Cpp.D) -> Cpp.C {
// 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.406738f1b62008ed:core.Destroy.Core"(ptr %.loc25_35.1.temp), !dbg !73
// CHECK:STDOUT: call void @"_COp.43bece552030817c:core.Destroy.Core"(ptr %.loc24_32.1.temp), !dbg !72
// CHECK:STDOUT: call void @"_COp.ecaf8c3e76291eee:core.Destroy.Core"(ptr %.loc20_35.1.temp), !dbg !71
// CHECK:STDOUT: call void @"_COp.3de38e83520d6bec:core.Destroy.Core"(ptr %.loc19_32.1.temp), !dbg !70
// CHECK:STDOUT: call void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr %.loc25_35.1.temp), !dbg !73
// CHECK:STDOUT: call void @"_COp.4bf3b2f84a23e67d:core.Destroy.Core"(ptr %.loc24_32.1.temp), !dbg !72
// CHECK:STDOUT: call void @"_COp.4f41a08d65e2a5a3:core.Destroy.Core"(ptr %.loc20_35.1.temp), !dbg !71
// CHECK:STDOUT: call void @"_COp.471bf32d53e15da8:core.Destroy.Core"(ptr %.loc19_32.1.temp), !dbg !70
// CHECK:STDOUT: ret void, !dbg !79
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.406738f1b62008ed:core.Destroy.Core"(ptr %self) #0 !dbg !80 {
// CHECK:STDOUT: define weak_odr void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr %self) #0 !dbg !80 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !85
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.43bece552030817c:core.Destroy.Core"(ptr %self) #0 !dbg !86 {
// CHECK:STDOUT: define weak_odr void @"_COp.4bf3b2f84a23e67d:core.Destroy.Core"(ptr %self) #0 !dbg !86 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !91
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.ecaf8c3e76291eee:core.Destroy.Core"(ptr %self) #0 !dbg !92 {
// CHECK:STDOUT: define weak_odr void @"_COp.4f41a08d65e2a5a3:core.Destroy.Core"(ptr %self) #0 !dbg !92 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !97
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.3de38e83520d6bec:core.Destroy.Core"(ptr %self) #0 !dbg !98 {
// CHECK:STDOUT: define weak_odr void @"_COp.471bf32d53e15da8:core.Destroy.Core"(ptr %self) #0 !dbg !98 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !103
// CHECK:STDOUT: }
@@ -334,37 +334,37 @@ fn Call(x: Cpp.D) -> Cpp.C {
// 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.0d6779e60704359e:core.Destroy.Core"(ptr %my_i64.var), !dbg !112
// CHECK:STDOUT: call void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %my_i32.var), !dbg !111
// CHECK:STDOUT: call void @"_COp.406738f1b62008ed:core.Destroy.Core"(ptr %my_i16.var), !dbg !110
// CHECK:STDOUT: call void @"_COp.43bece552030817c:core.Destroy.Core"(ptr %my_i8.var), !dbg !109
// CHECK:STDOUT: call void @"_COp.798ffd80cf2992c3:core.Destroy.Core"(ptr %my_u64.var), !dbg !108
// CHECK:STDOUT: call void @"_COp.dab1523ded6661cc:core.Destroy.Core"(ptr %my_u32.var), !dbg !107
// CHECK:STDOUT: call void @"_COp.ecaf8c3e76291eee:core.Destroy.Core"(ptr %my_u16.var), !dbg !106
// CHECK:STDOUT: call void @"_COp.3de38e83520d6bec:core.Destroy.Core"(ptr %my_u8.var), !dbg !105
// CHECK:STDOUT: call void @"_COp.8c3f43cf50902723:core.Destroy.Core"(ptr %my_i64.var), !dbg !112
// CHECK:STDOUT: call void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %my_i32.var), !dbg !111
// CHECK:STDOUT: call void @"_COp.7b4d46d56ede77d9:core.Destroy.Core"(ptr %my_i16.var), !dbg !110
// CHECK:STDOUT: call void @"_COp.4bf3b2f84a23e67d:core.Destroy.Core"(ptr %my_i8.var), !dbg !109
// CHECK:STDOUT: call void @"_COp.184f05bfd26f6354:core.Destroy.Core"(ptr %my_u64.var), !dbg !108
// CHECK:STDOUT: call void @"_COp.355b0c2a1e63d439:core.Destroy.Core"(ptr %my_u32.var), !dbg !107
// CHECK:STDOUT: call void @"_COp.4f41a08d65e2a5a3:core.Destroy.Core"(ptr %my_u16.var), !dbg !106
// CHECK:STDOUT: call void @"_COp.471bf32d53e15da8:core.Destroy.Core"(ptr %my_u8.var), !dbg !105
// CHECK:STDOUT: ret void, !dbg !130
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.0d6779e60704359e:core.Destroy.Core"(ptr %self) #0 !dbg !131 {
// CHECK:STDOUT: define weak_odr void @"_COp.8c3f43cf50902723:core.Destroy.Core"(ptr %self) #0 !dbg !131 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !136
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #0 !dbg !137 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #0 !dbg !137 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !142
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.798ffd80cf2992c3:core.Destroy.Core"(ptr %self) #0 !dbg !143 {
// CHECK:STDOUT: define weak_odr void @"_COp.184f05bfd26f6354:core.Destroy.Core"(ptr %self) #0 !dbg !143 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !148
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.dab1523ded6661cc:core.Destroy.Core"(ptr %self) #0 !dbg !149 {
// CHECK:STDOUT: define weak_odr void @"_COp.355b0c2a1e63d439:core.Destroy.Core"(ptr %self) #0 !dbg !149 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !154
// CHECK:STDOUT: }
@@ -472,25 +472,25 @@ fn Call(x: Cpp.D) -> Cpp.C {
// 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.406738f1b62008ed:core.Destroy.Core", scope: null, file: !6, line: 25, type: !81, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !83)
// CHECK:STDOUT: !80 = distinct !DISubprogram(name: "Op", linkageName: "_COp.7b4d46d56ede77d9:core.Destroy.Core", scope: null, file: !6, line: 25, type: !81, spFlags: DISPFlagDefinition, unit: !5, 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.43bece552030817c:core.Destroy.Core", scope: null, file: !6, line: 24, type: !87, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !89)
// CHECK:STDOUT: !86 = distinct !DISubprogram(name: "Op", linkageName: "_COp.4bf3b2f84a23e67d:core.Destroy.Core", scope: null, file: !6, line: 24, type: !87, spFlags: DISPFlagDefinition, unit: !5, 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.ecaf8c3e76291eee:core.Destroy.Core", scope: null, file: !6, line: 20, type: !93, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !95)
// CHECK:STDOUT: !92 = distinct !DISubprogram(name: "Op", linkageName: "_COp.4f41a08d65e2a5a3:core.Destroy.Core", scope: null, file: !6, line: 20, type: !93, spFlags: DISPFlagDefinition, unit: !5, 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.3de38e83520d6bec:core.Destroy.Core", scope: null, file: !6, line: 19, type: !99, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !101)
// CHECK:STDOUT: !98 = distinct !DISubprogram(name: "Op", linkageName: "_COp.471bf32d53e15da8:core.Destroy.Core", scope: null, file: !6, line: 19, type: !99, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !101)
// CHECK:STDOUT: !99 = !DISubroutineType(types: !100)
// CHECK:STDOUT: !100 = !{null, !14}
// CHECK:STDOUT: !101 = !{!102}
@@ -523,25 +523,25 @@ fn Call(x: Cpp.D) -> Cpp.C {
// 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.0d6779e60704359e:core.Destroy.Core", scope: null, file: !6, line: 41, type: !132, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !134)
// CHECK:STDOUT: !131 = distinct !DISubprogram(name: "Op", linkageName: "_COp.8c3f43cf50902723:core.Destroy.Core", scope: null, file: !6, line: 41, type: !132, spFlags: DISPFlagDefinition, unit: !5, 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.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 40, type: !138, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !140)
// CHECK:STDOUT: !137 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 40, type: !138, spFlags: DISPFlagDefinition, unit: !5, 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.798ffd80cf2992c3:core.Destroy.Core", scope: null, file: !6, line: 36, type: !144, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !146)
// CHECK:STDOUT: !143 = distinct !DISubprogram(name: "Op", linkageName: "_COp.184f05bfd26f6354:core.Destroy.Core", scope: null, file: !6, line: 36, type: !144, spFlags: DISPFlagDefinition, unit: !5, 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.dab1523ded6661cc:core.Destroy.Core", scope: null, file: !6, line: 35, type: !150, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !152)
// CHECK:STDOUT: !149 = distinct !DISubprogram(name: "Op", linkageName: "_COp.355b0c2a1e63d439:core.Destroy.Core", scope: null, file: !6, line: 35, type: !150, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !152)
// CHECK:STDOUT: !150 = !DISubroutineType(types: !151)
// CHECK:STDOUT: !151 = !{null, !34}
// CHECK:STDOUT: !152 = !{!153}
+25 -25
View File
@@ -272,24 +272,24 @@ fn G() {
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.A.Main"(ptr %self) #4 !dbg !18 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.1afa5e4ee26f3f8f:core.Destroy.Core"(ptr %self), !dbg !24
// CHECK:STDOUT: call void @"_COp.dfeb4630c74d91bf:core.Destroy.Core"(ptr %self), !dbg !24
// CHECK:STDOUT: ret void, !dbg !24
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #5 !dbg !25 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #5 !dbg !25 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !31
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.ce21b459230035a4:core.Destroy.Core"(ptr %self) #5 !dbg !32 {
// CHECK:STDOUT: define weak_odr void @"_COp.16e1f573fc35f00d:core.Destroy.Core"(ptr %self) #5 !dbg !32 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !35
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.1afa5e4ee26f3f8f:core.Destroy.Core"(ptr %self) #5 !dbg !36 {
// CHECK:STDOUT: define weak_odr void @"_COp.dfeb4630c74d91bf:core.Destroy.Core"(ptr %self) #5 !dbg !36 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !39
// CHECK:STDOUT: }
@@ -305,18 +305,18 @@ fn G() {
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.B.Main"(ptr %self) #4 !dbg !44 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.301c2cde953858ec:core.Destroy.Core"(ptr %self), !dbg !47
// CHECK:STDOUT: call void @"_COp.26d3d5cf28fab2d1:core.Destroy.Core"(ptr %self), !dbg !47
// CHECK:STDOUT: ret void, !dbg !47
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.1a8ac7d7e1ca560e:core.Destroy.Core"(ptr %self) #5 !dbg !48 {
// CHECK:STDOUT: define weak_odr void @"_COp.1064d6e04bf2b941:core.Destroy.Core"(ptr %self) #5 !dbg !48 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !51
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.301c2cde953858ec:core.Destroy.Core"(ptr %self) #5 !dbg !52 {
// CHECK:STDOUT: define weak_odr void @"_COp.26d3d5cf28fab2d1:core.Destroy.Core"(ptr %self) #5 !dbg !52 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !55
// CHECK:STDOUT: }
@@ -332,18 +332,18 @@ fn G() {
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.C.Main"(ptr %self) #4 !dbg !60 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.71e25083d63c4d6c:core.Destroy.Core"(ptr %self), !dbg !63
// CHECK:STDOUT: call void @"_COp.00eaf0142c0c6297:core.Destroy.Core"(ptr %self), !dbg !63
// CHECK:STDOUT: ret void, !dbg !63
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.e9c7e36fd2e174ea:core.Destroy.Core"(ptr %self) #5 !dbg !64 {
// CHECK:STDOUT: define weak_odr void @"_COp.2378edb07d37432b:core.Destroy.Core"(ptr %self) #5 !dbg !64 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !67
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.71e25083d63c4d6c:core.Destroy.Core"(ptr %self) #5 !dbg !68 {
// CHECK:STDOUT: define weak_odr void @"_COp.00eaf0142c0c6297:core.Destroy.Core"(ptr %self) #5 !dbg !68 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !71
// CHECK:STDOUT: }
@@ -395,18 +395,18 @@ fn G() {
// CHECK:STDOUT: !22 = !{!23}
// CHECK:STDOUT: !23 = !DILocalVariable(arg: 1, scope: !18, type: !21)
// CHECK:STDOUT: !24 = !DILocation(line: 6, column: 1, scope: !18)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 6, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 6, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !26 = !DISubroutineType(types: !27)
// CHECK:STDOUT: !27 = !{null, !28}
// CHECK:STDOUT: !28 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !29 = !{!30}
// CHECK:STDOUT: !30 = !DILocalVariable(arg: 1, scope: !25, type: !28)
// CHECK:STDOUT: !31 = !DILocation(line: 6, column: 1, scope: !25)
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "Op", linkageName: "_COp.ce21b459230035a4:core.Destroy.Core", scope: null, file: !6, line: 6, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !33)
// CHECK:STDOUT: !32 = distinct !DISubprogram(name: "Op", linkageName: "_COp.16e1f573fc35f00d:core.Destroy.Core", scope: null, file: !6, line: 6, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !33)
// CHECK:STDOUT: !33 = !{!34}
// CHECK:STDOUT: !34 = !DILocalVariable(arg: 1, scope: !32, type: !21)
// CHECK:STDOUT: !35 = !DILocation(line: 6, column: 1, scope: !32)
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1afa5e4ee26f3f8f:core.Destroy.Core", scope: null, file: !6, line: 6, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !37)
// CHECK:STDOUT: !36 = distinct !DISubprogram(name: "Op", linkageName: "_COp.dfeb4630c74d91bf:core.Destroy.Core", scope: null, file: !6, line: 6, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !37)
// CHECK:STDOUT: !37 = !{!38}
// CHECK:STDOUT: !38 = !DILocalVariable(arg: 1, scope: !36, type: !21)
// CHECK:STDOUT: !39 = !DILocation(line: 6, column: 1, scope: !36)
@@ -418,11 +418,11 @@ fn G() {
// CHECK:STDOUT: !45 = !{!46}
// CHECK:STDOUT: !46 = !DILocalVariable(arg: 1, scope: !44, type: !21)
// CHECK:STDOUT: !47 = !DILocation(line: 11, column: 1, scope: !44)
// CHECK:STDOUT: !48 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1a8ac7d7e1ca560e:core.Destroy.Core", scope: null, file: !6, line: 11, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !49)
// CHECK:STDOUT: !48 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1064d6e04bf2b941:core.Destroy.Core", scope: null, file: !6, line: 11, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !49)
// CHECK:STDOUT: !49 = !{!50}
// CHECK:STDOUT: !50 = !DILocalVariable(arg: 1, scope: !48, type: !21)
// CHECK:STDOUT: !51 = !DILocation(line: 11, column: 1, scope: !48)
// CHECK:STDOUT: !52 = distinct !DISubprogram(name: "Op", linkageName: "_COp.301c2cde953858ec:core.Destroy.Core", scope: null, file: !6, line: 11, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !53)
// CHECK:STDOUT: !52 = distinct !DISubprogram(name: "Op", linkageName: "_COp.26d3d5cf28fab2d1:core.Destroy.Core", scope: null, file: !6, line: 11, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !53)
// CHECK:STDOUT: !53 = !{!54}
// CHECK:STDOUT: !54 = !DILocalVariable(arg: 1, scope: !52, type: !21)
// CHECK:STDOUT: !55 = !DILocation(line: 11, column: 1, scope: !52)
@@ -434,11 +434,11 @@ fn G() {
// CHECK:STDOUT: !61 = !{!62}
// CHECK:STDOUT: !62 = !DILocalVariable(arg: 1, scope: !60, type: !21)
// CHECK:STDOUT: !63 = !DILocation(line: 16, column: 1, scope: !60)
// CHECK:STDOUT: !64 = distinct !DISubprogram(name: "Op", linkageName: "_COp.e9c7e36fd2e174ea:core.Destroy.Core", scope: null, file: !6, line: 16, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !65)
// CHECK:STDOUT: !64 = distinct !DISubprogram(name: "Op", linkageName: "_COp.2378edb07d37432b:core.Destroy.Core", scope: null, file: !6, line: 16, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !65)
// CHECK:STDOUT: !65 = !{!66}
// CHECK:STDOUT: !66 = !DILocalVariable(arg: 1, scope: !64, type: !21)
// CHECK:STDOUT: !67 = !DILocation(line: 16, column: 1, scope: !64)
// CHECK:STDOUT: !68 = distinct !DISubprogram(name: "Op", linkageName: "_COp.71e25083d63c4d6c:core.Destroy.Core", scope: null, file: !6, line: 16, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !69)
// CHECK:STDOUT: !68 = distinct !DISubprogram(name: "Op", linkageName: "_COp.00eaf0142c0c6297:core.Destroy.Core", scope: null, file: !6, line: 16, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !69)
// CHECK:STDOUT: !69 = !{!70}
// CHECK:STDOUT: !70 = !DILocalVariable(arg: 1, scope: !68, type: !21)
// CHECK:STDOUT: !71 = !DILocation(line: 16, column: 1, scope: !68)
@@ -472,24 +472,24 @@ fn G() {
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.C.Main"(ptr %self) #1 !dbg !19 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.71e25083d63c4d6c:core.Destroy.Core"(ptr %self), !dbg !25
// CHECK:STDOUT: call void @"_COp.62e953a927ca4e4e:core.Destroy.Core"(ptr %self), !dbg !25
// CHECK:STDOUT: ret void, !dbg !25
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #2 !dbg !26 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #2 !dbg !26 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !32
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.fb32c4dfca65e378:core.Destroy.Core"(ptr %self) #2 !dbg !33 {
// CHECK:STDOUT: define weak_odr void @"_COp.57e275a610bca340:core.Destroy.Core"(ptr %self) #2 !dbg !33 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !36
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.71e25083d63c4d6c:core.Destroy.Core"(ptr %self) #2 !dbg !37 {
// CHECK:STDOUT: define weak_odr void @"_COp.62e953a927ca4e4e:core.Destroy.Core"(ptr %self) #2 !dbg !37 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !40
// CHECK:STDOUT: }
@@ -503,7 +503,7 @@ fn G() {
// CHECK:STDOUT: %.loc19_29.6.b = getelementptr inbounds nuw { i32, i32 }, ptr %c.var, i32 0, i32 1, !dbg !45
// CHECK:STDOUT: call void @llvm.memcpy.p0.p0.i64(ptr align 4 %c.var, ptr align 4 @C.val.loc19_3, i64 8, i1 false), !dbg !44
// CHECK:STDOUT: call void @_Z1FRN6Carbon1CE(ptr %c.var), !dbg !46
// CHECK:STDOUT: call void @"_COp.71e25083d63c4d6c:core.Destroy.Core"(ptr %c.var), !dbg !44
// CHECK:STDOUT: call void @"_COp.62e953a927ca4e4e:core.Destroy.Core"(ptr %c.var), !dbg !44
// CHECK:STDOUT: ret void, !dbg !47
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -548,18 +548,18 @@ fn G() {
// CHECK:STDOUT: !23 = !{!24}
// CHECK:STDOUT: !24 = !DILocalVariable(arg: 1, scope: !19, type: !22)
// CHECK:STDOUT: !25 = !DILocation(line: 6, column: 1, scope: !19)
// CHECK:STDOUT: !26 = distinct !DISubprogram(name: "Op", linkageName: "_COp.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 6, type: !27, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !30)
// CHECK:STDOUT: !26 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 6, type: !27, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !30)
// CHECK:STDOUT: !27 = !DISubroutineType(types: !28)
// CHECK:STDOUT: !28 = !{null, !29}
// CHECK:STDOUT: !29 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !30 = !{!31}
// CHECK:STDOUT: !31 = !DILocalVariable(arg: 1, scope: !26, type: !29)
// CHECK:STDOUT: !32 = !DILocation(line: 6, column: 1, scope: !26)
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.fb32c4dfca65e378:core.Destroy.Core", scope: null, file: !6, line: 6, type: !20, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !34)
// CHECK:STDOUT: !33 = distinct !DISubprogram(name: "Op", linkageName: "_COp.57e275a610bca340:core.Destroy.Core", scope: null, file: !6, line: 6, type: !20, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !34)
// CHECK:STDOUT: !34 = !{!35}
// CHECK:STDOUT: !35 = !DILocalVariable(arg: 1, scope: !33, type: !22)
// CHECK:STDOUT: !36 = !DILocation(line: 6, column: 1, scope: !33)
// CHECK:STDOUT: !37 = distinct !DISubprogram(name: "Op", linkageName: "_COp.71e25083d63c4d6c:core.Destroy.Core", scope: null, file: !6, line: 6, type: !20, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !38)
// CHECK:STDOUT: !37 = distinct !DISubprogram(name: "Op", linkageName: "_COp.62e953a927ca4e4e:core.Destroy.Core", scope: null, file: !6, line: 6, type: !20, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !38)
// CHECK:STDOUT: !38 = !{!39}
// CHECK:STDOUT: !39 = !DILocalVariable(arg: 1, scope: !37, type: !22)
// CHECK:STDOUT: !40 = !DILocation(line: 6, column: 1, scope: !37)
+9 -9
View File
@@ -118,12 +118,12 @@ fn CallCallF() { Cpp.CallF(); }
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.A.Main"(ptr %self) #5 !dbg !21 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.1afa5e4ee26f3f8f:core.Destroy.Core"(ptr %self), !dbg !24
// CHECK:STDOUT: call void @"_COp.4f97b17816379516:core.Destroy.Core"(ptr %self), !dbg !24
// CHECK:STDOUT: ret void, !dbg !24
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.1afa5e4ee26f3f8f:core.Destroy.Core"(ptr %self) #4 !dbg !25 {
// CHECK:STDOUT: define weak_odr void @"_COp.4f97b17816379516:core.Destroy.Core"(ptr %self) #4 !dbg !25 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !28
// CHECK:STDOUT: }
@@ -171,7 +171,7 @@ fn CallCallF() { Cpp.CallF(); }
// CHECK:STDOUT: !22 = !{!23}
// CHECK:STDOUT: !23 = !DILocalVariable(arg: 1, scope: !21, type: !17)
// CHECK:STDOUT: !24 = !DILocation(line: 5, column: 1, scope: !21)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1afa5e4ee26f3f8f:core.Destroy.Core", scope: null, file: !6, line: 5, type: !15, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !26)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.4f97b17816379516:core.Destroy.Core", scope: null, file: !6, line: 5, type: !15, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !26)
// CHECK:STDOUT: !26 = !{!27}
// CHECK:STDOUT: !27 = !DILocalVariable(arg: 1, scope: !25, type: !17)
// CHECK:STDOUT: !28 = !DILocation(line: 5, column: 1, scope: !25)
@@ -238,12 +238,12 @@ fn CallCallF() { Cpp.CallF(); }
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.A.Main"(ptr %self) #5 !dbg !23 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.1afa5e4ee26f3f8f:core.Destroy.Core"(ptr %self), !dbg !28
// CHECK:STDOUT: call void @"_COp.70edc238a819ff9f:core.Destroy.Core"(ptr %self), !dbg !28
// CHECK:STDOUT: ret void, !dbg !28
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.1afa5e4ee26f3f8f:core.Destroy.Core"(ptr %self) #4 !dbg !29 {
// CHECK:STDOUT: define weak_odr void @"_COp.70edc238a819ff9f:core.Destroy.Core"(ptr %self) #4 !dbg !29 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !32
// CHECK:STDOUT: }
@@ -304,7 +304,7 @@ fn CallCallF() { Cpp.CallF(); }
// CHECK:STDOUT: !26 = !{!27}
// CHECK:STDOUT: !27 = !DILocalVariable(arg: 1, scope: !23, type: !18)
// CHECK:STDOUT: !28 = !DILocation(line: 5, column: 1, scope: !23)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1afa5e4ee26f3f8f:core.Destroy.Core", scope: null, file: !6, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !30)
// CHECK:STDOUT: !29 = distinct !DISubprogram(name: "Op", linkageName: "_COp.70edc238a819ff9f:core.Destroy.Core", scope: null, file: !6, line: 5, type: !24, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !30)
// CHECK:STDOUT: !30 = !{!31}
// CHECK:STDOUT: !31 = !DILocalVariable(arg: 1, scope: !29, type: !18)
// CHECK:STDOUT: !32 = !DILocation(line: 5, column: 1, scope: !29)
@@ -349,12 +349,12 @@ fn CallCallF() { Cpp.CallF(); }
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_C__destroy_thunk:thunk.A.Main"(ptr %self) #3 !dbg !15 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @"_COp.1afa5e4ee26f3f8f:core.Destroy.Core"(ptr %self), !dbg !21
// CHECK:STDOUT: call void @"_COp.618b79babf1755d1:core.Destroy.Core"(ptr %self), !dbg !21
// CHECK:STDOUT: ret void, !dbg !21
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.1afa5e4ee26f3f8f:core.Destroy.Core"(ptr %self) #2 !dbg !22 {
// CHECK:STDOUT: define weak_odr void @"_COp.618b79babf1755d1:core.Destroy.Core"(ptr %self) #2 !dbg !22 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !25
// CHECK:STDOUT: }
@@ -404,7 +404,7 @@ fn CallCallF() { Cpp.CallF(); }
// CHECK:STDOUT: !19 = !{!20}
// CHECK:STDOUT: !20 = !DILocalVariable(arg: 1, scope: !15, type: !18)
// CHECK:STDOUT: !21 = !DILocation(line: 5, column: 1, scope: !15)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1afa5e4ee26f3f8f:core.Destroy.Core", scope: null, file: !6, line: 5, type: !16, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !23)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "Op", linkageName: "_COp.618b79babf1755d1:core.Destroy.Core", scope: null, file: !6, line: 5, type: !16, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !23)
// CHECK:STDOUT: !23 = !{!24}
// CHECK:STDOUT: !24 = !DILocalVariable(arg: 1, scope: !22, type: !18)
// CHECK:STDOUT: !25 = !DILocation(line: 5, column: 1, scope: !22)
@@ -146,18 +146,18 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: %initializer_list.initializer_list.call.init_list.end = getelementptr inbounds nuw [16 x i8], ptr %_.var, i32 0, i32 8, !dbg !14
// CHECK:STDOUT: store ptr getelementptr inbounds ([3 x i32], ptr @array.loc13_50.15, i32 1), ptr %initializer_list.initializer_list.call.init_list.end, align 8, !dbg !14
// CHECK:STDOUT: call void @_CWithinLifetime.Main(), !dbg !16
// CHECK:STDOUT: call void @"_COp.bfd302cd235977c4:core.Destroy.Core"(ptr @array), !dbg !15
// CHECK:STDOUT: call void @"_COp.1c95d180afb5f529:core.Destroy.Core"(ptr @array), !dbg !15
// CHECK:STDOUT: ret void, !dbg !17
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #0 !dbg !18 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #0 !dbg !18 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !24
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.bfd302cd235977c4:core.Destroy.Core"(ptr %self) #0 !dbg !25 {
// CHECK:STDOUT: define weak_odr void @"_COp.1c95d180afb5f529:core.Destroy.Core"(ptr %self) #0 !dbg !25 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !31
// CHECK:STDOUT: }
@@ -180,7 +180,7 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: store ptr getelementptr inbounds ([3 x i32], ptr @array.loc13_50.15, i32 1), ptr %initializer_list.initializer_list.call.init_list.end, align 8, !dbg !34
// CHECK:STDOUT: call void @_ZN11vector_likeC1ESt16initializer_listIiE.carbon_thunk._(ptr %.loc18_36.2.temp, ptr %_.var), !dbg !33
// CHECK:STDOUT: call void @_CWithinLifetime.Main(), !dbg !35
// CHECK:STDOUT: call void @"_COp.bfd302cd235977c4:core.Destroy.Core"(ptr @array), !dbg !34
// CHECK:STDOUT: call void @"_COp.1c95d180afb5f529:core.Destroy.Core"(ptr @array), !dbg !34
// CHECK:STDOUT: call void @_ZN11vector_likeD2Ev(ptr %_.var), !dbg !33
// CHECK:STDOUT: ret void, !dbg !36
// CHECK:STDOUT: }
@@ -232,7 +232,7 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: %initializer_list.initializer_list.call.array.end = getelementptr inbounds [3 x [1 x i8]], ptr %.loc23_69.17.temp, i32 1, !dbg !46
// CHECK:STDOUT: store ptr %initializer_list.initializer_list.call.array.end, ptr %initializer_list.initializer_list.call.init_list.end, align 8, !dbg !46
// CHECK:STDOUT: call void @_CWithinLifetime.Main(), !dbg !48
// CHECK:STDOUT: call void @"_COp.3c5ceecfa63e1bfb:core.Destroy.Core"(ptr %.loc23_69.17.temp), !dbg !47
// CHECK:STDOUT: call void @"_COp.9ec0fd7c1ee9da2c:core.Destroy.Core"(ptr %.loc23_69.17.temp), !dbg !47
// CHECK:STDOUT: ret void, !dbg !49
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -256,7 +256,7 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.3c5ceecfa63e1bfb:core.Destroy.Core"(ptr %self) #0 !dbg !52 {
// CHECK:STDOUT: define weak_odr void @"_COp.9ec0fd7c1ee9da2c:core.Destroy.Core"(ptr %self) #0 !dbg !52 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !55
// CHECK:STDOUT: }
@@ -321,14 +321,14 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: !15 = !DILocation(line: 13, column: 42, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 14, column: 3, scope: !11)
// CHECK:STDOUT: !17 = !DILocation(line: 12, column: 1, scope: !11)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "Op", linkageName: "_COp.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 13, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !22)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 13, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !22)
// CHECK:STDOUT: !19 = !DISubroutineType(types: !20)
// CHECK:STDOUT: !20 = !{null, !21}
// CHECK:STDOUT: !21 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !22 = !{!23}
// CHECK:STDOUT: !23 = !DILocalVariable(arg: 1, scope: !18, type: !21)
// CHECK:STDOUT: !24 = !DILocation(line: 13, column: 42, scope: !18)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.bfd302cd235977c4:core.Destroy.Core", scope: null, file: !6, line: 13, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1c95d180afb5f529:core.Destroy.Core", scope: null, file: !6, line: 13, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !26 = !DISubroutineType(types: !27)
// CHECK:STDOUT: !27 = !{null, !28}
// CHECK:STDOUT: !28 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
@@ -355,7 +355,7 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: !49 = !DILocation(line: 22, column: 1, scope: !45)
// CHECK:STDOUT: !50 = !{!51, !51, i64 0}
// CHECK:STDOUT: !51 = !{!"p1 _ZTS15nontrivial_dtor", !39, i64 0}
// CHECK:STDOUT: !52 = distinct !DISubprogram(name: "Op", linkageName: "_COp.3c5ceecfa63e1bfb:core.Destroy.Core", scope: null, file: !6, line: 23, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !53)
// CHECK:STDOUT: !52 = distinct !DISubprogram(name: "Op", linkageName: "_COp.9ec0fd7c1ee9da2c:core.Destroy.Core", scope: null, file: !6, line: 23, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !53)
// CHECK:STDOUT: !53 = !{!54}
// CHECK:STDOUT: !54 = !DILocalVariable(arg: 1, scope: !52, type: !28)
// CHECK:STDOUT: !55 = !DILocation(line: 23, column: 58, scope: !52)
@@ -394,18 +394,18 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: %initializer_list.initializer_list.call.init_list.size = getelementptr inbounds nuw [16 x i8], ptr %_.var, i32 0, i32 8, !dbg !14
// CHECK:STDOUT: store i64 3, ptr %initializer_list.initializer_list.call.init_list.size, align 8, !dbg !14
// CHECK:STDOUT: call void @_CWithinLifetime.Main(), !dbg !16
// CHECK:STDOUT: call void @"_COp.bfd302cd235977c4:core.Destroy.Core"(ptr @array), !dbg !15
// CHECK:STDOUT: call void @"_COp.1c95d180afb5f529:core.Destroy.Core"(ptr @array), !dbg !15
// CHECK:STDOUT: ret void, !dbg !17
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.7e389eab4a7e5487:core.Destroy.Core"(ptr %self) #0 !dbg !18 {
// CHECK:STDOUT: define weak_odr void @"_COp.94e3ca86614aba5d:core.Destroy.Core"(ptr %self) #0 !dbg !18 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !24
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.bfd302cd235977c4:core.Destroy.Core"(ptr %self) #0 !dbg !25 {
// CHECK:STDOUT: define weak_odr void @"_COp.1c95d180afb5f529:core.Destroy.Core"(ptr %self) #0 !dbg !25 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !31
// CHECK:STDOUT: }
@@ -428,7 +428,7 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: store i64 3, ptr %initializer_list.initializer_list.call.init_list.size, align 8, !dbg !34
// CHECK:STDOUT: call void @_ZN11vector_likeC1ESt16initializer_listIiE.carbon_thunk._(ptr %.loc18_36.2.temp, ptr %_.var), !dbg !33
// CHECK:STDOUT: call void @_CWithinLifetime.Main(), !dbg !35
// CHECK:STDOUT: call void @"_COp.bfd302cd235977c4:core.Destroy.Core"(ptr @array), !dbg !34
// CHECK:STDOUT: call void @"_COp.1c95d180afb5f529:core.Destroy.Core"(ptr @array), !dbg !34
// CHECK:STDOUT: call void @_ZN11vector_likeD2Ev(ptr %_.var), !dbg !33
// CHECK:STDOUT: ret void, !dbg !36
// CHECK:STDOUT: }
@@ -479,7 +479,7 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: %initializer_list.initializer_list.call.init_list.size = getelementptr inbounds nuw [16 x i8], ptr %_.var, i32 0, i32 8, !dbg !48
// CHECK:STDOUT: store i64 3, ptr %initializer_list.initializer_list.call.init_list.size, align 8, !dbg !48
// CHECK:STDOUT: call void @_CWithinLifetime.Main(), !dbg !50
// CHECK:STDOUT: call void @"_COp.3c5ceecfa63e1bfb:core.Destroy.Core"(ptr %.loc23_69.17.temp), !dbg !49
// CHECK:STDOUT: call void @"_COp.9ec0fd7c1ee9da2c:core.Destroy.Core"(ptr %.loc23_69.17.temp), !dbg !49
// CHECK:STDOUT: ret void, !dbg !51
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -503,7 +503,7 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.3c5ceecfa63e1bfb:core.Destroy.Core"(ptr %self) #0 !dbg !54 {
// CHECK:STDOUT: define weak_odr void @"_COp.9ec0fd7c1ee9da2c:core.Destroy.Core"(ptr %self) #0 !dbg !54 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !57
// CHECK:STDOUT: }
@@ -568,14 +568,14 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: !15 = !DILocation(line: 13, column: 42, scope: !11)
// CHECK:STDOUT: !16 = !DILocation(line: 14, column: 3, scope: !11)
// CHECK:STDOUT: !17 = !DILocation(line: 12, column: 1, scope: !11)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "Op", linkageName: "_COp.7e389eab4a7e5487:core.Destroy.Core", scope: null, file: !6, line: 13, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !22)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "Op", linkageName: "_COp.94e3ca86614aba5d:core.Destroy.Core", scope: null, file: !6, line: 13, type: !19, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !22)
// CHECK:STDOUT: !19 = !DISubroutineType(types: !20)
// CHECK:STDOUT: !20 = !{null, !21}
// CHECK:STDOUT: !21 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
// CHECK:STDOUT: !22 = !{!23}
// CHECK:STDOUT: !23 = !DILocalVariable(arg: 1, scope: !18, type: !21)
// CHECK:STDOUT: !24 = !DILocation(line: 13, column: 42, scope: !18)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.bfd302cd235977c4:core.Destroy.Core", scope: null, file: !6, line: 13, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !25 = distinct !DISubprogram(name: "Op", linkageName: "_COp.1c95d180afb5f529:core.Destroy.Core", scope: null, file: !6, line: 13, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !29)
// CHECK:STDOUT: !26 = !DISubroutineType(types: !27)
// CHECK:STDOUT: !27 = !{null, !28}
// CHECK:STDOUT: !28 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: null, size: 64)
@@ -604,7 +604,7 @@ fn InitNontrivialDtor() {
// CHECK:STDOUT: !51 = !DILocation(line: 22, column: 1, scope: !47)
// CHECK:STDOUT: !52 = !{!53, !53, i64 0}
// CHECK:STDOUT: !53 = !{!"p1 _ZTS15nontrivial_dtor", !39, i64 0}
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "Op", linkageName: "_COp.3c5ceecfa63e1bfb:core.Destroy.Core", scope: null, file: !6, line: 23, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !55)
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "Op", linkageName: "_COp.9ec0fd7c1ee9da2c:core.Destroy.Core", scope: null, file: !6, line: 23, type: !26, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !55)
// CHECK:STDOUT: !55 = !{!56}
// CHECK:STDOUT: !56 = !DILocalVariable(arg: 1, scope: !54, type: !28)
// CHECK:STDOUT: !57 = !DILocation(line: 23, column: 58, scope: !54)
+4 -4
View File
@@ -61,14 +61,14 @@ fn Call(n: Cpp.NeedThunk) {
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Copy.fdeb6dbda014bd1f.Core:NeedThunk.Cpp"(ptr sret([1 x i8]) %return, ptr %self) #2 !dbg !23 {
// CHECK:STDOUT: define void @"_COp:thunk:Copy.13bba1feb543d868.Core:NeedThunk.Cpp"(ptr sret([1 x i8]) %return, ptr %self) #2 !dbg !23 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_ZN9NeedThunkC1ERKS_.carbon_thunk._(ptr %self, ptr %return), !dbg !29
// CHECK:STDOUT: ret void, !dbg !29
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define void @"_COp:thunk:Destroy.91afe58d20fe9768.Core:NeedThunk.Cpp"(ptr %self) #2 !dbg !30 {
// CHECK:STDOUT: define void @"_COp:thunk:Destroy.57797f2517cd78d7.Core:NeedThunk.Cpp"(ptr %self) #2 !dbg !30 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !33
// CHECK:STDOUT: }
@@ -114,14 +114,14 @@ fn Call(n: Cpp.NeedThunk) {
// CHECK:STDOUT: !20 = !{!21, !21, i64 0}
// CHECK:STDOUT: !21 = !{!"p1 _ZTS9NeedThunk", !22, i64 0}
// CHECK:STDOUT: !22 = !{!"any pointer", !9, i64 0}
// CHECK:STDOUT: !23 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Copy.fdeb6dbda014bd1f.Core:NeedThunk.Cpp", scope: null, file: !24, line: 4, type: !25, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !27)
// CHECK:STDOUT: !23 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Copy.13bba1feb543d868.Core:NeedThunk.Cpp", scope: null, file: !24, line: 4, type: !25, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !27)
// CHECK:STDOUT: !24 = !DIFile(filename: "./need_thunk.h", directory: "")
// CHECK:STDOUT: !25 = !DISubroutineType(types: !26)
// CHECK:STDOUT: !26 = !{!14, !14}
// CHECK:STDOUT: !27 = !{!28}
// CHECK:STDOUT: !28 = !DILocalVariable(arg: 1, scope: !23, type: !14)
// CHECK:STDOUT: !29 = !DILocation(line: 4, column: 3, scope: !23)
// CHECK:STDOUT: !30 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Destroy.91afe58d20fe9768.Core:NeedThunk.Cpp", scope: null, file: !24, line: 5, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !31)
// CHECK:STDOUT: !30 = distinct !DISubprogram(name: "Op", linkageName: "_COp:thunk:Destroy.57797f2517cd78d7.Core:NeedThunk.Cpp", scope: null, file: !24, line: 5, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !31)
// CHECK:STDOUT: !31 = !{!32}
// CHECK:STDOUT: !32 = !DILocalVariable(arg: 1, scope: !30, type: !14)
// CHECK:STDOUT: !33 = !DILocation(line: 5, column: 3, scope: !30)
+51 -51
View File
@@ -65,25 +65,25 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: define void @_CPassVoidPtr.Main(ptr %a) #0 !dbg !11 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc7_21.2.temp = alloca ptr, align 8, !dbg !17
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.e136e0ec20a6aa88"(ptr %a), !dbg !17
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.bc8a88dae0c7117a"(ptr %a), !dbg !17
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc7_21.2.temp), !dbg !17
// CHECK:STDOUT: store ptr %U.as_type.as.ImplicitAs.impl.Convert.call, ptr %.loc7_21.2.temp, align 8, !dbg !17
// CHECK:STDOUT: %.loc7_21.4 = load ptr, ptr %.loc7_21.2.temp, align 8, !dbg !17
// CHECK:STDOUT: call void @_Z13take_void_ptrPv(ptr %.loc7_21.4), !dbg !18
// CHECK:STDOUT: call void @"_COp.9f6b24296baa7133:core.Destroy.Core"(ptr %.loc7_21.2.temp), !dbg !17
// CHECK:STDOUT: call void @"_COp.29cb36961ff3e7a9:core.Destroy.Core"(ptr %.loc7_21.2.temp), !dbg !17
// CHECK:STDOUT: ret void, !dbg !19
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_Z13take_void_ptrPv(ptr noundef) #1
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.39ca70f0f5ff2105:core.Destroy.Core"(ptr %self) #0 !dbg !20 {
// CHECK:STDOUT: define weak_odr void @"_COp.6caaa969dc8d525b:core.Destroy.Core"(ptr %self) #0 !dbg !20 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !23
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.9f6b24296baa7133:core.Destroy.Core"(ptr %self) #0 !dbg !24 {
// CHECK:STDOUT: define weak_odr void @"_COp.29cb36961ff3e7a9:core.Destroy.Core"(ptr %self) #0 !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: }
@@ -92,12 +92,12 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: define void @_CPassIntPtr.Main(ptr %a) #0 !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc11_21.2.temp = alloca ptr, align 8, !dbg !31
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.1b842e63cff4a61c"(ptr %a), !dbg !31
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.a84fab117d3c0ee6"(ptr %a), !dbg !31
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc11_21.2.temp), !dbg !31
// CHECK:STDOUT: store ptr %U.as_type.as.ImplicitAs.impl.Convert.call, ptr %.loc11_21.2.temp, align 8, !dbg !31
// CHECK:STDOUT: %.loc11_21.4 = load ptr, ptr %.loc11_21.2.temp, align 8, !dbg !31
// CHECK:STDOUT: call void @_Z13take_void_ptrPv(ptr %.loc11_21.4), !dbg !32
// CHECK:STDOUT: call void @"_COp.9f6b24296baa7133:core.Destroy.Core"(ptr %.loc11_21.2.temp), !dbg !31
// CHECK:STDOUT: call void @"_COp.29cb36961ff3e7a9:core.Destroy.Core"(ptr %.loc11_21.2.temp), !dbg !31
// CHECK:STDOUT: ret void, !dbg !33
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -105,25 +105,25 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: define void @_CPassIntPtrToConstVoidPtr.Main(ptr %a) #0 !dbg !34 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc15_27.2.temp = alloca ptr, align 8, !dbg !37
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.2bf614c074969566"(ptr %a), !dbg !37
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.aed2bb692dd6cdfe"(ptr %a), !dbg !37
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc15_27.2.temp), !dbg !37
// CHECK:STDOUT: store ptr %U.as_type.as.ImplicitAs.impl.Convert.call, ptr %.loc15_27.2.temp, align 8, !dbg !37
// CHECK:STDOUT: %.loc15_27.4 = load ptr, ptr %.loc15_27.2.temp, align 8, !dbg !37
// CHECK:STDOUT: call void @_Z19take_const_void_ptrPKv(ptr %.loc15_27.4), !dbg !38
// CHECK:STDOUT: call void @"_COp.f02948c192ea69df:core.Destroy.Core"(ptr %.loc15_27.2.temp), !dbg !37
// CHECK:STDOUT: call void @"_COp.8aa3827fca3a355d:core.Destroy.Core"(ptr %.loc15_27.2.temp), !dbg !37
// CHECK:STDOUT: ret void, !dbg !39
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare void @_Z19take_const_void_ptrPKv(ptr noundef) #1
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.02b26c7ebd9c0872:core.Destroy.Core"(ptr %self) #0 !dbg !40 {
// CHECK:STDOUT: define weak_odr void @"_COp.f56221e914a74d60:core.Destroy.Core"(ptr %self) #0 !dbg !40 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !43
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define weak_odr void @"_COp.f02948c192ea69df:core.Destroy.Core"(ptr %self) #0 !dbg !44 {
// CHECK:STDOUT: define weak_odr void @"_COp.8aa3827fca3a355d:core.Destroy.Core"(ptr %self) #0 !dbg !44 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: ret void, !dbg !47
// CHECK:STDOUT: }
@@ -132,18 +132,18 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: define void @_CPassConstIntPtrToConstVoidPtr.Main(ptr %a) #0 !dbg !48 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc19_27.2.temp = alloca ptr, align 8, !dbg !51
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.2bf614c074969566"(ptr %a), !dbg !51
// CHECK:STDOUT: %U.as_type.as.ImplicitAs.impl.Convert.call = call ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.aed2bb692dd6cdfe"(ptr %a), !dbg !51
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc19_27.2.temp), !dbg !51
// CHECK:STDOUT: store ptr %U.as_type.as.ImplicitAs.impl.Convert.call, ptr %.loc19_27.2.temp, align 8, !dbg !51
// CHECK:STDOUT: %.loc19_27.4 = load ptr, ptr %.loc19_27.2.temp, align 8, !dbg !51
// CHECK:STDOUT: call void @_Z19take_const_void_ptrPKv(ptr %.loc19_27.4), !dbg !52
// CHECK:STDOUT: call void @"_COp.f02948c192ea69df:core.Destroy.Core"(ptr %.loc19_27.2.temp), !dbg !51
// CHECK:STDOUT: call void @"_COp.8aa3827fca3a355d:core.Destroy.Core"(ptr %.loc19_27.2.temp), !dbg !51
// CHECK:STDOUT: ret void, !dbg !53
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.e136e0ec20a6aa88"(ptr %self) #0 !dbg !54 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.a15aada625dab765:OptionalAs.0e326e799dad0c64.Core.b9f265e82399d23b"(ptr %self), !dbg !60
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.bc8a88dae0c7117a"(ptr %self) #0 !dbg !54 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.ba9a17e320476215:OptionalAs.7eef99cd03a74de4.Core.58daef9740f71e43"(ptr %self), !dbg !60
// CHECK:STDOUT: ret ptr %1, !dbg !61
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -151,87 +151,87 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #2
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.1b842e63cff4a61c"(ptr %self) #0 !dbg !62 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.81a1ecd9155a3498:OptionalAs.f58b2ba767714873.Core.baec405a0949f32c"(ptr %self), !dbg !65
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.a84fab117d3c0ee6"(ptr %self) #0 !dbg !62 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.62d55c5523334675:OptionalAs.f5e7d4305ac1f327.Core.598d3d2f1309c543"(ptr %self), !dbg !65
// CHECK:STDOUT: ret ptr %1, !dbg !66
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.2bf614c074969566"(ptr %self) #0 !dbg !67 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.81a1ecd9155a3498:OptionalAs.f58b2ba767714873.Core.030cb6453373b89b"(ptr %self), !dbg !70
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.aed2bb692dd6cdfe"(ptr %self) #0 !dbg !67 {
// CHECK:STDOUT: %1 = call ptr @"_CConvert.62d55c5523334675:OptionalAs.f5e7d4305ac1f327.Core.5cd669b97de7611a"(ptr %self), !dbg !70
// CHECK:STDOUT: ret ptr %1, !dbg !71
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.a15aada625dab765:OptionalAs.0e326e799dad0c64.Core.b9f265e82399d23b"(ptr %self) #0 !dbg !72 {
// CHECK:STDOUT: %1 = call ptr @_CSome.Optional.Core.b9f265e82399d23b(ptr %self), !dbg !75
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.ba9a17e320476215:OptionalAs.7eef99cd03a74de4.Core.58daef9740f71e43"(ptr %self) #0 !dbg !72 {
// CHECK:STDOUT: %1 = call ptr @_CSome.Optional.Core.58daef9740f71e43(ptr %self), !dbg !75
// CHECK:STDOUT: ret ptr %1, !dbg !76
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.81a1ecd9155a3498:OptionalAs.f58b2ba767714873.Core.baec405a0949f32c"(ptr %self) #0 !dbg !77 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.62d55c5523334675:OptionalAs.f5e7d4305ac1f327.Core.598d3d2f1309c543"(ptr %self) #0 !dbg !77 {
// CHECK:STDOUT: %temp = alloca ptr, align 8, !dbg !80
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %temp), !dbg !80
// CHECK:STDOUT: store ptr %self, ptr %temp, align 8, !dbg !80
// CHECK:STDOUT: %1 = load ptr, ptr %temp, align 8, !dbg !80
// CHECK:STDOUT: %2 = call ptr @_CSome.Optional.Core.b9f265e82399d23b(ptr %1), !dbg !81
// CHECK:STDOUT: %2 = call ptr @_CSome.Optional.Core.58daef9740f71e43(ptr %1), !dbg !81
// CHECK:STDOUT: ret ptr %2, !dbg !82
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.81a1ecd9155a3498:OptionalAs.f58b2ba767714873.Core.030cb6453373b89b"(ptr %self) #0 !dbg !83 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert.62d55c5523334675:OptionalAs.f5e7d4305ac1f327.Core.5cd669b97de7611a"(ptr %self) #0 !dbg !83 {
// CHECK:STDOUT: %temp = alloca ptr, align 8, !dbg !86
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %temp), !dbg !86
// CHECK:STDOUT: %1 = call ptr @"_CConvert:thunk:ImplicitAs.a2a0c15925bee468.Core:e8f8f92d3d08d149:ImplicitAs.ffd58aeb29886b72.Core.b88d1103f417c6d4"(ptr %self), !dbg !86
// CHECK:STDOUT: %1 = call ptr @"_CConvert:thunk:ImplicitAs.18b29766acf27da3.Core:e8f8f92d3d08d149:ImplicitAs.c8091dc115c4eb3f.Core.c8fd090a2e741f70"(ptr %self), !dbg !86
// CHECK:STDOUT: store ptr %1, ptr %temp, align 8, !dbg !86
// CHECK:STDOUT: %2 = load ptr, ptr %temp, align 8, !dbg !86
// CHECK:STDOUT: %3 = call ptr @_CSome.Optional.Core.f238af349d589061(ptr %2), !dbg !87
// CHECK:STDOUT: %3 = call ptr @_CSome.Optional.Core.6be97cf0783728aa(ptr %2), !dbg !87
// CHECK:STDOUT: ret ptr %3, !dbg !88
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @_CSome.Optional.Core.b9f265e82399d23b(ptr %value) #0 !dbg !89 {
// CHECK:STDOUT: %1 = call ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.a3238f3d1f6ba299"(ptr %value), !dbg !92
// CHECK:STDOUT: define linkonce_odr ptr @_CSome.Optional.Core.58daef9740f71e43(ptr %value) #0 !dbg !89 {
// CHECK:STDOUT: %1 = call ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.e002d6765e4506fc"(ptr %value), !dbg !92
// CHECK:STDOUT: ret ptr %1, !dbg !93
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: alwaysinline nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert:thunk:ImplicitAs.a2a0c15925bee468.Core:e8f8f92d3d08d149:ImplicitAs.ffd58aeb29886b72.Core.b88d1103f417c6d4"(ptr %self) #3 !dbg !94 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CConvert:thunk:ImplicitAs.18b29766acf27da3.Core:e8f8f92d3d08d149:ImplicitAs.c8091dc115c4eb3f.Core.c8fd090a2e741f70"(ptr %self) #3 !dbg !94 {
// CHECK:STDOUT: ret ptr %self, !dbg !98
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @_CSome.Optional.Core.f238af349d589061(ptr %value) #0 !dbg !99 {
// CHECK:STDOUT: %1 = call ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.2e8a3baa837dcd9f"(ptr %value), !dbg !102
// CHECK:STDOUT: define linkonce_odr ptr @_CSome.Optional.Core.6be97cf0783728aa(ptr %value) #0 !dbg !99 {
// CHECK:STDOUT: %1 = call ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.de7664f1c7ce4d43"(ptr %value), !dbg !102
// CHECK:STDOUT: ret ptr %1, !dbg !103
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.a3238f3d1f6ba299"(ptr %self) #0 !dbg !104 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.e002d6765e4506fc"(ptr %self) #0 !dbg !104 {
// CHECK:STDOUT: %1 = alloca ptr, align 8, !dbg !107
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %1), !dbg !107
// CHECK:STDOUT: store ptr poison, ptr %1, align 8, !dbg !107
// CHECK:STDOUT: store ptr %self, ptr %1, align 8, !dbg !108
// CHECK:STDOUT: %2 = load ptr, ptr %1, align 8, !dbg !109
// CHECK:STDOUT: call void @"_COp.39ca70f0f5ff2105:core.Destroy.Core"(ptr %1), !dbg !107
// CHECK:STDOUT: call void @"_COp.6caaa969dc8d525b:core.Destroy.Core"(ptr %1), !dbg !107
// CHECK:STDOUT: ret ptr %2, !dbg !110
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nounwind
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.2e8a3baa837dcd9f"(ptr %self) #0 !dbg !111 {
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.de7664f1c7ce4d43"(ptr %self) #0 !dbg !111 {
// CHECK:STDOUT: %1 = alloca ptr, align 8, !dbg !114
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %1), !dbg !114
// CHECK:STDOUT: store ptr poison, ptr %1, align 8, !dbg !114
// CHECK:STDOUT: store ptr %self, ptr %1, align 8, !dbg !115
// CHECK:STDOUT: %2 = load ptr, ptr %1, align 8, !dbg !116
// CHECK:STDOUT: call void @"_COp.02b26c7ebd9c0872:core.Destroy.Core"(ptr %1), !dbg !114
// CHECK:STDOUT: call void @"_COp.f56221e914a74d60:core.Destroy.Core"(ptr %1), !dbg !114
// CHECK:STDOUT: ret ptr %2, !dbg !117
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; uselistorder directives
// CHECK:STDOUT: uselistorder ptr @llvm.lifetime.start.p0, { 0, 1, 2, 3, 7, 6, 5, 4 }
// CHECK:STDOUT: uselistorder ptr @"_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.2bf614c074969566", { 1, 0 }
// CHECK:STDOUT: uselistorder ptr @_CSome.Optional.Core.b9f265e82399d23b, { 1, 0 }
// CHECK:STDOUT: uselistorder ptr @"_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.aed2bb692dd6cdfe", { 1, 0 }
// CHECK:STDOUT: uselistorder ptr @_CSome.Optional.Core.58daef9740f71e43, { 1, 0 }
// CHECK:STDOUT:
// CHECK:STDOUT: attributes #0 = { nounwind }
// CHECK:STDOUT: attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
@@ -262,11 +262,11 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: !17 = !DILocation(line: 7, column: 21, scope: !11)
// CHECK:STDOUT: !18 = !DILocation(line: 7, column: 3, scope: !11)
// CHECK:STDOUT: !19 = !DILocation(line: 6, column: 1, scope: !11)
// CHECK:STDOUT: !20 = distinct !DISubprogram(name: "Op", linkageName: "_COp.39ca70f0f5ff2105:core.Destroy.Core", scope: null, file: !6, line: 7, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !21)
// CHECK:STDOUT: !20 = distinct !DISubprogram(name: "Op", linkageName: "_COp.6caaa969dc8d525b:core.Destroy.Core", scope: null, file: !6, line: 7, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !21)
// CHECK:STDOUT: !21 = !{!22}
// CHECK:STDOUT: !22 = !DILocalVariable(arg: 1, scope: !20, type: !14)
// CHECK:STDOUT: !23 = !DILocation(line: 7, column: 21, scope: !20)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Op", linkageName: "_COp.9f6b24296baa7133:core.Destroy.Core", scope: null, file: !6, line: 7, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !25)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "Op", linkageName: "_COp.29cb36961ff3e7a9:core.Destroy.Core", scope: null, file: !6, line: 7, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !25)
// CHECK:STDOUT: !25 = !{!26}
// CHECK:STDOUT: !26 = !DILocalVariable(arg: 1, scope: !24, type: !14)
// CHECK:STDOUT: !27 = !DILocation(line: 7, column: 21, scope: !24)
@@ -282,11 +282,11 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: !37 = !DILocation(line: 15, column: 27, scope: !34)
// CHECK:STDOUT: !38 = !DILocation(line: 15, column: 3, scope: !34)
// CHECK:STDOUT: !39 = !DILocation(line: 14, column: 1, scope: !34)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "Op", linkageName: "_COp.02b26c7ebd9c0872:core.Destroy.Core", scope: null, file: !6, line: 15, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !41)
// CHECK:STDOUT: !40 = distinct !DISubprogram(name: "Op", linkageName: "_COp.f56221e914a74d60:core.Destroy.Core", scope: null, file: !6, line: 15, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !41)
// CHECK:STDOUT: !41 = !{!42}
// CHECK:STDOUT: !42 = !DILocalVariable(arg: 1, scope: !40, type: !14)
// CHECK:STDOUT: !43 = !DILocation(line: 15, column: 27, scope: !40)
// CHECK:STDOUT: !44 = distinct !DISubprogram(name: "Op", linkageName: "_COp.f02948c192ea69df:core.Destroy.Core", scope: null, file: !6, line: 15, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !45)
// CHECK:STDOUT: !44 = distinct !DISubprogram(name: "Op", linkageName: "_COp.8aa3827fca3a355d:core.Destroy.Core", scope: null, file: !6, line: 15, type: !12, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !45)
// CHECK:STDOUT: !45 = !{!46}
// CHECK:STDOUT: !46 = !DILocalVariable(arg: 1, scope: !44, type: !14)
// CHECK:STDOUT: !47 = !DILocation(line: 15, column: 27, scope: !44)
@@ -296,7 +296,7 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: !51 = !DILocation(line: 19, column: 27, scope: !48)
// CHECK:STDOUT: !52 = !DILocation(line: 19, column: 3, scope: !48)
// CHECK:STDOUT: !53 = !DILocation(line: 18, column: 1, scope: !48)
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.e136e0ec20a6aa88", scope: null, file: !55, line: 96, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !58)
// CHECK:STDOUT: !54 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.bc8a88dae0c7117a", scope: null, file: !55, line: 96, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !58)
// CHECK:STDOUT: !55 = !DIFile(filename: "{{.*}}/prelude/types/optional.carbon", directory: "")
// CHECK:STDOUT: !56 = !DISubroutineType(types: !57)
// CHECK:STDOUT: !57 = !{!14, !14}
@@ -304,56 +304,56 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
// CHECK:STDOUT: !59 = !DILocalVariable(arg: 1, scope: !54, type: !14)
// CHECK:STDOUT: !60 = !DILocation(line: 97, column: 12, scope: !54)
// CHECK:STDOUT: !61 = !DILocation(line: 97, column: 5, scope: !54)
// CHECK:STDOUT: !62 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.1b842e63cff4a61c", scope: null, file: !55, line: 96, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !63)
// CHECK:STDOUT: !62 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.a84fab117d3c0ee6", scope: null, file: !55, line: 96, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !63)
// CHECK:STDOUT: !63 = !{!64}
// CHECK:STDOUT: !64 = !DILocalVariable(arg: 1, scope: !62, type: !14)
// CHECK:STDOUT: !65 = !DILocation(line: 97, column: 12, scope: !62)
// CHECK:STDOUT: !66 = !DILocation(line: 97, column: 5, scope: !62)
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.81f236ae340cbf98:ImplicitAs.0f95c9e18c91e00a.Core.2bf614c074969566", scope: null, file: !55, line: 96, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !68)
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.6391a65a70757668:ImplicitAs.116c0b3f4fb552e2.Core.aed2bb692dd6cdfe", scope: null, file: !55, line: 96, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !68)
// CHECK:STDOUT: !68 = !{!69}
// CHECK:STDOUT: !69 = !DILocalVariable(arg: 1, scope: !67, type: !14)
// CHECK:STDOUT: !70 = !DILocation(line: 97, column: 12, scope: !67)
// CHECK:STDOUT: !71 = !DILocation(line: 97, column: 5, scope: !67)
// CHECK:STDOUT: !72 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.a15aada625dab765:OptionalAs.0e326e799dad0c64.Core.b9f265e82399d23b", scope: null, file: !55, line: 71, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !73)
// CHECK:STDOUT: !72 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.ba9a17e320476215:OptionalAs.7eef99cd03a74de4.Core.58daef9740f71e43", scope: null, file: !55, line: 71, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !73)
// CHECK:STDOUT: !73 = !{!74}
// CHECK:STDOUT: !74 = !DILocalVariable(arg: 1, scope: !72, type: !14)
// CHECK:STDOUT: !75 = !DILocation(line: 72, column: 12, scope: !72)
// CHECK:STDOUT: !76 = !DILocation(line: 72, column: 5, scope: !72)
// CHECK:STDOUT: !77 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.81a1ecd9155a3498:OptionalAs.f58b2ba767714873.Core.baec405a0949f32c", scope: null, file: !55, line: 78, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !78)
// CHECK:STDOUT: !77 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.62d55c5523334675:OptionalAs.f5e7d4305ac1f327.Core.598d3d2f1309c543", scope: null, file: !55, line: 78, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !78)
// CHECK:STDOUT: !78 = !{!79}
// CHECK:STDOUT: !79 = !DILocalVariable(arg: 1, scope: !77, type: !14)
// CHECK:STDOUT: !80 = !DILocation(line: 79, column: 29, scope: !77)
// CHECK:STDOUT: !81 = !DILocation(line: 79, column: 12, scope: !77)
// CHECK:STDOUT: !82 = !DILocation(line: 79, column: 5, scope: !77)
// CHECK:STDOUT: !83 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.81a1ecd9155a3498:OptionalAs.f58b2ba767714873.Core.030cb6453373b89b", scope: null, file: !55, line: 78, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !84)
// CHECK:STDOUT: !83 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.62d55c5523334675:OptionalAs.f5e7d4305ac1f327.Core.5cd669b97de7611a", scope: null, file: !55, line: 78, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !84)
// CHECK:STDOUT: !84 = !{!85}
// CHECK:STDOUT: !85 = !DILocalVariable(arg: 1, scope: !83, type: !14)
// CHECK:STDOUT: !86 = !DILocation(line: 79, column: 29, scope: !83)
// CHECK:STDOUT: !87 = !DILocation(line: 79, column: 12, scope: !83)
// CHECK:STDOUT: !88 = !DILocation(line: 79, column: 5, scope: !83)
// CHECK:STDOUT: !89 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.b9f265e82399d23b", scope: null, file: !55, line: 30, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !90)
// CHECK:STDOUT: !89 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.58daef9740f71e43", scope: null, file: !55, line: 30, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !90)
// CHECK:STDOUT: !90 = !{!91}
// CHECK:STDOUT: !91 = !DILocalVariable(arg: 1, scope: !89, type: !14)
// CHECK:STDOUT: !92 = !DILocation(line: 31, column: 12, scope: !89)
// CHECK:STDOUT: !93 = !DILocation(line: 31, column: 5, scope: !89)
// CHECK:STDOUT: !94 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert:thunk:ImplicitAs.a2a0c15925bee468.Core:e8f8f92d3d08d149:ImplicitAs.ffd58aeb29886b72.Core.b88d1103f417c6d4", scope: null, file: !95, line: 40, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !96)
// CHECK:STDOUT: !94 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert:thunk:ImplicitAs.18b29766acf27da3.Core:e8f8f92d3d08d149:ImplicitAs.c8091dc115c4eb3f.Core.c8fd090a2e741f70", scope: null, file: !95, line: 40, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !96)
// CHECK:STDOUT: !95 = !DIFile(filename: "{{.*}}/prelude/types/cpp/void.carbon", directory: "")
// CHECK:STDOUT: !96 = !{!97}
// CHECK:STDOUT: !97 = !DILocalVariable(arg: 1, scope: !94, type: !14)
// CHECK:STDOUT: !98 = !DILocation(line: 40, column: 3, scope: !94)
// CHECK:STDOUT: !99 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.f238af349d589061", scope: null, file: !55, line: 30, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !100)
// CHECK:STDOUT: !99 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.6be97cf0783728aa", scope: null, file: !55, line: 30, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !100)
// CHECK:STDOUT: !100 = !{!101}
// CHECK:STDOUT: !101 = !DILocalVariable(arg: 1, scope: !99, type: !14)
// CHECK:STDOUT: !102 = !DILocation(line: 31, column: 12, scope: !99)
// CHECK:STDOUT: !103 = !DILocation(line: 31, column: 5, scope: !99)
// CHECK:STDOUT: !104 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.a3238f3d1f6ba299", scope: null, file: !55, line: 150, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !105)
// CHECK:STDOUT: !104 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.e002d6765e4506fc", scope: null, file: !55, line: 150, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !105)
// CHECK:STDOUT: !105 = !{!106}
// CHECK:STDOUT: !106 = !DILocalVariable(arg: 1, scope: !104, type: !14)
// CHECK:STDOUT: !107 = !DILocation(line: 151, column: 14, scope: !104)
// CHECK:STDOUT: !108 = !DILocation(line: 153, column: 5, scope: !104)
// CHECK:STDOUT: !109 = !DILocation(line: 151, column: 18, scope: !104)
// CHECK:STDOUT: !110 = !DILocation(line: 154, column: 5, scope: !104)
// CHECK:STDOUT: !111 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.2e8a3baa837dcd9f", scope: null, file: !55, line: 150, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !112)
// CHECK:STDOUT: !111 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.de7664f1c7ce4d43", scope: null, file: !55, line: 150, type: !56, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !112)
// CHECK:STDOUT: !112 = !{!113}
// CHECK:STDOUT: !113 = !DILocalVariable(arg: 1, scope: !111, type: !14)
// CHECK:STDOUT: !114 = !DILocation(line: 151, column: 14, scope: !111)