Make FacetAccessType evaluate to SymbolicBindingType for type-of a BindSymbolicName (#6115)

The SymbolicBindingType refers to the type value that will be
substituted in for the BindSymbolicName, but holds onto the EntityNameId
from the BindSymbolicName instead of (or in addition to, for now) the
instruction.

The EntityNameId will be used to look in the ScopeStack to find the
witnesses either from the BindSymbolicName instruction, or other
instructions that specify `impls` constraints against the EntityName.

This will allow us to have the `T` in `I(T)` resolve to a `.Self`
reference in the type so that we get type equality with the binding's
type: `T:! I(.Self)`.
This commit is contained in:
Dana Jansens
2025-10-06 18:56:43 +00:00
committed by GitHub
parent bd4d5805dd
commit fe020ee08b
237 changed files with 7827 additions and 7586 deletions
@@ -85,12 +85,12 @@ fn M() {
// CHECK:STDOUT: %.loc54 = load i32, ptr %n.var, align 4, !dbg !13
// CHECK:STDOUT: call void @_CF.Main.b88d1103f417c6d4(i32 %.loc54), !dbg !14
// CHECK:STDOUT: %.loc55_9 = load i32, ptr %n.var, align 4, !dbg !15
// CHECK:STDOUT: %G.call.loc55 = call i32 @_CG.Main.5458818be7a67202(i32 %.loc55_9), !dbg !16
// CHECK:STDOUT: %G.call.loc55 = call i32 @_CG.Main.c831c62a6babb214(i32 %.loc55_9), !dbg !16
// CHECK:STDOUT: store i32 %G.call.loc55, ptr %m.var, align 4, !dbg !17
// CHECK:STDOUT: %.loc56 = load double, ptr %p.var, align 8, !dbg !18
// CHECK:STDOUT: call void @_CF.Main.d4b5665541d5d7a8(double %.loc56), !dbg !19
// CHECK:STDOUT: %.loc57_9 = load double, ptr %p.var, align 8, !dbg !20
// CHECK:STDOUT: %G.call.loc57 = call double @_CG.Main.6d1061d836075fdf(double %.loc57_9), !dbg !21
// CHECK:STDOUT: %G.call.loc57 = call double @_CG.Main.54ba0c5f7a576a29(double %.loc57_9), !dbg !21
// CHECK:STDOUT: store double %G.call.loc57, ptr %q.var, align 8, !dbg !22
// CHECK:STDOUT: ret void, !dbg !23
// CHECK:STDOUT: }
@@ -106,7 +106,7 @@ fn M() {
// CHECK:STDOUT: ret void, !dbg !25
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr i32 @_CG.Main.5458818be7a67202(i32 %x) !dbg !26 {
// CHECK:STDOUT: define linkonce_odr i32 @_CG.Main.c831c62a6babb214(i32 %x) !dbg !26 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc29_6.3.temp = alloca i32, align 4, !dbg !27
// CHECK:STDOUT: %.loc31_8.3.temp = alloca i32, align 4, !dbg !28
@@ -122,7 +122,7 @@ fn M() {
// CHECK:STDOUT: store i32 %H.call.loc29, ptr %.loc29_6.3.temp, align 4, !dbg !27
// CHECK:STDOUT: %H.call.loc30 = call %type @_CH.Main.402deed6b8733082(%type zeroinitializer), !dbg !36
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc31_8.3.temp), !dbg !28
// CHECK:STDOUT: %G.call = call i32 @_CG.Main.5458818be7a67202(i32 %x), !dbg !28
// CHECK:STDOUT: %G.call = call i32 @_CG.Main.c831c62a6babb214(i32 %x), !dbg !28
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc31_9.3.temp), !dbg !29
// CHECK:STDOUT: store i32 %G.call, ptr %.loc31_8.3.temp, align 4, !dbg !28
// CHECK:STDOUT: %.loc31_8.5 = load i32, ptr %.loc31_8.3.temp, align 4, !dbg !28
@@ -151,7 +151,7 @@ fn M() {
// CHECK:STDOUT: ret void, !dbg !47
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr double @_CG.Main.6d1061d836075fdf(double %x) !dbg !48 {
// CHECK:STDOUT: define linkonce_odr double @_CG.Main.54ba0c5f7a576a29(double %x) !dbg !48 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc29_6.3.temp = alloca double, align 8, !dbg !49
// CHECK:STDOUT: %.loc31_8.3.temp = alloca double, align 8, !dbg !50
@@ -167,7 +167,7 @@ fn M() {
// CHECK:STDOUT: store double %H.call.loc29, ptr %.loc29_6.3.temp, align 8, !dbg !49
// CHECK:STDOUT: %H.call.loc30 = call %type @_CH.Main.402deed6b8733082(%type zeroinitializer), !dbg !58
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc31_8.3.temp), !dbg !50
// CHECK:STDOUT: %G.call = call double @_CG.Main.6d1061d836075fdf(double %x), !dbg !50
// CHECK:STDOUT: %G.call = call double @_CG.Main.54ba0c5f7a576a29(double %x), !dbg !50
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc31_9.3.temp), !dbg !51
// CHECK:STDOUT: store double %G.call, ptr %.loc31_8.3.temp, align 8, !dbg !50
// CHECK:STDOUT: %.loc31_8.5 = load double, ptr %.loc31_8.3.temp, align 8, !dbg !50
@@ -257,7 +257,7 @@ fn M() {
// CHECK:STDOUT: !23 = !DILocation(line: 48, column: 1, scope: !8)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.b88d1103f417c6d4", scope: null, file: !3, line: 19, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !25 = !DILocation(line: 19, column: 1, scope: !24)
// CHECK:STDOUT: !26 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.5458818be7a67202", scope: null, file: !3, line: 28, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !26 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.c831c62a6babb214", scope: null, file: !3, line: 28, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !27 = !DILocation(line: 29, column: 3, scope: !26)
// CHECK:STDOUT: !28 = !DILocation(line: 31, column: 5, scope: !26)
// CHECK:STDOUT: !29 = !DILocation(line: 31, column: 3, scope: !26)
@@ -279,7 +279,7 @@ fn M() {
// CHECK:STDOUT: !45 = !DILocation(line: 45, column: 3, scope: !26)
// CHECK:STDOUT: !46 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.d4b5665541d5d7a8", scope: null, file: !3, line: 19, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !47 = !DILocation(line: 19, column: 1, scope: !46)
// CHECK:STDOUT: !48 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.6d1061d836075fdf", scope: null, file: !3, line: 28, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !48 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.54ba0c5f7a576a29", scope: null, file: !3, line: 28, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !49 = !DILocation(line: 29, column: 3, scope: !48)
// CHECK:STDOUT: !50 = !DILocation(line: 31, column: 5, scope: !48)
// CHECK:STDOUT: !51 = !DILocation(line: 31, column: 3, scope: !48)
@@ -48,7 +48,7 @@ fn M() {
// CHECK:STDOUT: %.loc34 = load i32, ptr %n.var, align 4, !dbg !9
// CHECK:STDOUT: call void @_CF.Main.b88d1103f417c6d4(i32 %.loc34), !dbg !10
// CHECK:STDOUT: %.loc35_9 = load i32, ptr %n.var, align 4, !dbg !11
// CHECK:STDOUT: %G.call = call i32 @_CG.Main.5458818be7a67202(i32 %.loc35_9), !dbg !12
// CHECK:STDOUT: %G.call = call i32 @_CG.Main.c831c62a6babb214(i32 %.loc35_9), !dbg !12
// CHECK:STDOUT: store i32 %G.call, ptr %m.var, align 4, !dbg !13
// CHECK:STDOUT: ret void, !dbg !14
// CHECK:STDOUT: }
@@ -61,7 +61,7 @@ fn M() {
// CHECK:STDOUT: ret void, !dbg !16
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr i32 @_CG.Main.5458818be7a67202(i32 %x) !dbg !17 {
// CHECK:STDOUT: define linkonce_odr i32 @_CG.Main.c831c62a6babb214(i32 %x) !dbg !17 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc25_6.3.temp = alloca i32, align 4, !dbg !18
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc25_6.3.temp), !dbg !18
@@ -102,7 +102,7 @@ fn M() {
// CHECK:STDOUT: !14 = !DILocation(line: 30, column: 1, scope: !4)
// CHECK:STDOUT: !15 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.b88d1103f417c6d4", scope: null, file: !3, line: 16, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !16 = !DILocation(line: 16, column: 1, scope: !15)
// CHECK:STDOUT: !17 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.5458818be7a67202", scope: null, file: !3, line: 24, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !17 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.c831c62a6babb214", scope: null, file: !3, line: 24, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !18 = !DILocation(line: 25, column: 3, scope: !17)
// CHECK:STDOUT: !19 = !DILocation(line: 26, column: 3, scope: !17)
// CHECK:STDOUT: !20 = !DILocation(line: 27, column: 3, scope: !17)
@@ -52,26 +52,26 @@ fn M() {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %ptr_i32.var), !dbg !7
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %ptr_f64.var), !dbg !8
// CHECK:STDOUT: %.loc39_5 = load ptr, ptr %ptr_i32.var, align 8, !dbg !9
// CHECK:STDOUT: call void @_CF.Main.5458818be7a67202(ptr %.loc39_5), !dbg !10
// CHECK:STDOUT: call void @_CF.Main.c831c62a6babb214(ptr %.loc39_5), !dbg !10
// CHECK:STDOUT: %.loc40_5 = load ptr, ptr %ptr_f64.var, align 8, !dbg !11
// CHECK:STDOUT: call void @_CF.Main.6d1061d836075fdf(ptr %.loc40_5), !dbg !12
// CHECK:STDOUT: call void @_CF.Main.54ba0c5f7a576a29(ptr %.loc40_5), !dbg !12
// CHECK:STDOUT: ret void, !dbg !13
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #0
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.5458818be7a67202(ptr %x) !dbg !14 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.c831c62a6babb214(ptr %x) !dbg !14 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %A.call = call %type @_CA.Main.402deed6b8733082(%type zeroinitializer), !dbg !15
// CHECK:STDOUT: call void @_CB.Main.5458818be7a67202(ptr %x), !dbg !16
// CHECK:STDOUT: call void @_CB.Main.c831c62a6babb214(ptr %x), !dbg !16
// CHECK:STDOUT: ret void, !dbg !17
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.6d1061d836075fdf(ptr %x) !dbg !18 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.54ba0c5f7a576a29(ptr %x) !dbg !18 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %A.call = call %type @_CA.Main.402deed6b8733082(%type zeroinitializer), !dbg !19
// CHECK:STDOUT: call void @_CB.Main.6d1061d836075fdf(ptr %x), !dbg !20
// CHECK:STDOUT: call void @_CB.Main.54ba0c5f7a576a29(ptr %x), !dbg !20
// CHECK:STDOUT: ret void, !dbg !21
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -80,7 +80,7 @@ fn M() {
// CHECK:STDOUT: ret %type %x, !dbg !23
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CB.Main.5458818be7a67202(ptr %x) !dbg !24 {
// CHECK:STDOUT: define linkonce_odr void @_CB.Main.c831c62a6babb214(ptr %x) !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc27_7.3.temp = alloca i32, align 4, !dbg !25
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc27_7.3.temp), !dbg !25
@@ -90,7 +90,7 @@ fn M() {
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CB.Main.6d1061d836075fdf(ptr %x) !dbg !28 {
// CHECK:STDOUT: define linkonce_odr void @_CB.Main.54ba0c5f7a576a29(ptr %x) !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc27_7.3.temp = alloca double, align 8, !dbg !29
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc27_7.3.temp), !dbg !29
@@ -133,21 +133,21 @@ fn M() {
// CHECK:STDOUT: !11 = !DILocation(line: 40, column: 5, scope: !4)
// CHECK:STDOUT: !12 = !DILocation(line: 40, column: 3, scope: !4)
// CHECK:STDOUT: !13 = !DILocation(line: 35, column: 1, scope: !4)
// CHECK:STDOUT: !14 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.5458818be7a67202", scope: null, file: !3, line: 30, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !14 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.c831c62a6babb214", scope: null, file: !3, line: 30, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !15 = !DILocation(line: 31, column: 3, scope: !14)
// CHECK:STDOUT: !16 = !DILocation(line: 32, column: 3, scope: !14)
// CHECK:STDOUT: !17 = !DILocation(line: 30, column: 1, scope: !14)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.6d1061d836075fdf", scope: null, file: !3, line: 30, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.54ba0c5f7a576a29", scope: null, file: !3, line: 30, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !19 = !DILocation(line: 31, column: 3, scope: !18)
// CHECK:STDOUT: !20 = !DILocation(line: 32, column: 3, scope: !18)
// CHECK:STDOUT: !21 = !DILocation(line: 30, column: 1, scope: !18)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "A", linkageName: "_CA.Main.402deed6b8733082", scope: null, file: !3, line: 18, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !23 = !DILocation(line: 19, column: 3, scope: !22)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "B", linkageName: "_CB.Main.5458818be7a67202", scope: null, file: !3, line: 26, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "B", linkageName: "_CB.Main.c831c62a6babb214", scope: null, file: !3, line: 26, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !25 = !DILocation(line: 27, column: 3, scope: !24)
// CHECK:STDOUT: !26 = !DILocation(line: 27, column: 5, scope: !24)
// CHECK:STDOUT: !27 = !DILocation(line: 26, column: 1, scope: !24)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "B", linkageName: "_CB.Main.6d1061d836075fdf", scope: null, file: !3, line: 26, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "B", linkageName: "_CB.Main.54ba0c5f7a576a29", scope: null, file: !3, line: 26, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !29 = !DILocation(line: 27, column: 3, scope: !28)
// CHECK:STDOUT: !30 = !DILocation(line: 27, column: 5, scope: !28)
// CHECK:STDOUT: !31 = !DILocation(line: 26, column: 1, scope: !28)
@@ -61,14 +61,14 @@ fn Run() {
// CHECK:STDOUT:
// CHECK:STDOUT: define void @main() !dbg !12 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CG.Main.f84edebea9f363f0(), !dbg !13
// CHECK:STDOUT: call void @_CG.Main.b5f20a8e74ede332(), !dbg !14
// CHECK:STDOUT: call void @_CG.Main.734903ef36bb7752(), !dbg !13
// CHECK:STDOUT: call void @_CG.Main.a92ea42d6b971554(), !dbg !14
// CHECK:STDOUT: ret void, !dbg !15
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: declare i32 @printf(ptr, ...)
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CG.Main.f84edebea9f363f0() !dbg !16 {
// CHECK:STDOUT: define linkonce_odr void @_CG.Main.734903ef36bb7752() !dbg !16 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc37_20.1.temp = alloca i1, align 1, !dbg !17
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc37_20.1.temp), !dbg !17
@@ -80,7 +80,7 @@ fn Run() {
// CHECK:STDOUT: ret void, !dbg !18
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CG.Main.b5f20a8e74ede332() !dbg !19 {
// CHECK:STDOUT: define linkonce_odr void @_CG.Main.a92ea42d6b971554() !dbg !19 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc37_20.1.temp = alloca i32, align 4, !dbg !20
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc37_20.1.temp), !dbg !20
@@ -118,9 +118,9 @@ fn Run() {
// CHECK:STDOUT: !13 = !DILocation(line: 41, column: 3, scope: !12)
// CHECK:STDOUT: !14 = !DILocation(line: 42, column: 3, scope: !12)
// CHECK:STDOUT: !15 = !DILocation(line: 40, column: 1, scope: !12)
// CHECK:STDOUT: !16 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.f84edebea9f363f0", scope: null, file: !3, line: 36, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !16 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.734903ef36bb7752", scope: null, file: !3, line: 36, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !17 = !DILocation(line: 37, column: 16, scope: !16)
// CHECK:STDOUT: !18 = !DILocation(line: 36, column: 1, scope: !16)
// CHECK:STDOUT: !19 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.b5f20a8e74ede332", scope: null, file: !3, line: 36, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !19 = distinct !DISubprogram(name: "G", linkageName: "_CG.Main.a92ea42d6b971554", scope: null, file: !3, line: 36, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !20 = !DILocation(line: 37, column: 16, scope: !19)
// CHECK:STDOUT: !21 = !DILocation(line: 36, column: 1, scope: !19)
@@ -59,26 +59,26 @@ fn M() {
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %ptr_i32.var), !dbg !7
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %ptr_f64.var), !dbg !8
// CHECK:STDOUT: %.loc46_5 = load ptr, ptr %ptr_i32.var, align 8, !dbg !9
// CHECK:STDOUT: call void @_CF.Main.5458818be7a67202(ptr %.loc46_5), !dbg !10
// CHECK:STDOUT: call void @_CF.Main.c831c62a6babb214(ptr %.loc46_5), !dbg !10
// CHECK:STDOUT: %.loc47_5 = load ptr, ptr %ptr_f64.var, align 8, !dbg !11
// CHECK:STDOUT: call void @_CF.Main.6d1061d836075fdf(ptr %.loc47_5), !dbg !12
// CHECK:STDOUT: call void @_CF.Main.54ba0c5f7a576a29(ptr %.loc47_5), !dbg !12
// CHECK:STDOUT: ret void, !dbg !13
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #0
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.5458818be7a67202(ptr %x) !dbg !14 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.c831c62a6babb214(ptr %x) !dbg !14 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %A.call = call %type @_CA.Main.402deed6b8733082(%type zeroinitializer), !dbg !15
// CHECK:STDOUT: call void @_CB.Main.5458818be7a67202(ptr %x), !dbg !16
// CHECK:STDOUT: call void @_CB.Main.c831c62a6babb214(ptr %x), !dbg !16
// CHECK:STDOUT: ret void, !dbg !17
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.6d1061d836075fdf(ptr %x) !dbg !18 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.54ba0c5f7a576a29(ptr %x) !dbg !18 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %A.call = call %type @_CA.Main.402deed6b8733082(%type zeroinitializer), !dbg !19
// CHECK:STDOUT: call void @_CB.Main.6d1061d836075fdf(ptr %x), !dbg !20
// CHECK:STDOUT: call void @_CB.Main.54ba0c5f7a576a29(ptr %x), !dbg !20
// CHECK:STDOUT: ret void, !dbg !21
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -87,7 +87,7 @@ fn M() {
// CHECK:STDOUT: ret %type %x, !dbg !23
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CB.Main.5458818be7a67202(ptr %x) !dbg !24 {
// CHECK:STDOUT: define linkonce_odr void @_CB.Main.c831c62a6babb214(ptr %x) !dbg !24 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc34_7.3.temp = alloca i32, align 4, !dbg !25
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc34_7.3.temp), !dbg !25
@@ -97,7 +97,7 @@ fn M() {
// CHECK:STDOUT: ret void, !dbg !27
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CB.Main.6d1061d836075fdf(ptr %x) !dbg !28 {
// CHECK:STDOUT: define linkonce_odr void @_CB.Main.54ba0c5f7a576a29(ptr %x) !dbg !28 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %.loc34_7.3.temp = alloca double, align 8, !dbg !29
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc34_7.3.temp), !dbg !29
@@ -140,21 +140,21 @@ fn M() {
// CHECK:STDOUT: !11 = !DILocation(line: 47, column: 5, scope: !4)
// CHECK:STDOUT: !12 = !DILocation(line: 47, column: 3, scope: !4)
// CHECK:STDOUT: !13 = !DILocation(line: 42, column: 1, scope: !4)
// CHECK:STDOUT: !14 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.5458818be7a67202", scope: null, file: !3, line: 37, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !14 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.c831c62a6babb214", scope: null, file: !3, line: 37, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !15 = !DILocation(line: 38, column: 3, scope: !14)
// CHECK:STDOUT: !16 = !DILocation(line: 39, column: 3, scope: !14)
// CHECK:STDOUT: !17 = !DILocation(line: 37, column: 1, scope: !14)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.6d1061d836075fdf", scope: null, file: !3, line: 37, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !18 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.54ba0c5f7a576a29", scope: null, file: !3, line: 37, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !19 = !DILocation(line: 38, column: 3, scope: !18)
// CHECK:STDOUT: !20 = !DILocation(line: 39, column: 3, scope: !18)
// CHECK:STDOUT: !21 = !DILocation(line: 37, column: 1, scope: !18)
// CHECK:STDOUT: !22 = distinct !DISubprogram(name: "A", linkageName: "_CA.Main.402deed6b8733082", scope: null, file: !3, line: 25, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !23 = !DILocation(line: 26, column: 3, scope: !22)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "B", linkageName: "_CB.Main.5458818be7a67202", scope: null, file: !3, line: 33, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !24 = distinct !DISubprogram(name: "B", linkageName: "_CB.Main.c831c62a6babb214", scope: null, file: !3, line: 33, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !25 = !DILocation(line: 34, column: 3, scope: !24)
// CHECK:STDOUT: !26 = !DILocation(line: 34, column: 5, scope: !24)
// CHECK:STDOUT: !27 = !DILocation(line: 33, column: 1, scope: !24)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "B", linkageName: "_CB.Main.6d1061d836075fdf", scope: null, file: !3, line: 33, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !28 = distinct !DISubprogram(name: "B", linkageName: "_CB.Main.54ba0c5f7a576a29", scope: null, file: !3, line: 33, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !29 = !DILocation(line: 34, column: 3, scope: !28)
// CHECK:STDOUT: !30 = !DILocation(line: 34, column: 5, scope: !28)
// CHECK:STDOUT: !31 = !DILocation(line: 33, column: 1, scope: !28)
@@ -84,7 +84,7 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT:
// CHECK:STDOUT: define i32 @_CF_i32.Main(i32 %a) !dbg !8 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %F.call = call i32 @_CF.Main.6a6da5347b4dd84b(i32 %a), !dbg !9
// CHECK:STDOUT: %F.call = call i32 @_CF.Main.db99c030f99223d6(i32 %a), !dbg !9
// CHECK:STDOUT: ret i32 %F.call, !dbg !10
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -103,7 +103,7 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT:
// CHECK:STDOUT: define void @_CF_X.Main(ptr sret({ i32, i32 }) %return, ptr %a) !dbg !16 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CF.Main.287da2429e961b22(ptr %return, ptr %a), !dbg !17
// CHECK:STDOUT: call void @_CF.Main.eba3dea1578ec8e5(ptr %return, ptr %a), !dbg !17
// CHECK:STDOUT: ret void, !dbg !18
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -114,7 +114,7 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT:
// CHECK:STDOUT: define void @_CF_empty_tuple.Main() !dbg !21 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CF.Main.bcfa232a7f7e3dde(), !dbg !22
// CHECK:STDOUT: call void @_CF.Main.af8424a3d0a9008a(), !dbg !22
// CHECK:STDOUT: ret void, !dbg !23
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -133,7 +133,7 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT:
// CHECK:STDOUT: define void @_CF_two_tuple.Main(ptr sret({ i32, i32 }) %return, ptr %a) !dbg !27 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CF.Main.fd0a4d4c23847a64(ptr %return, ptr %a), !dbg !28
// CHECK:STDOUT: call void @_CF.Main.d67e493e33e87aab(ptr %return, ptr %a), !dbg !28
// CHECK:STDOUT: ret void, !dbg !29
// CHECK:STDOUT: }
// CHECK:STDOUT:
@@ -152,11 +152,11 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT:
// CHECK:STDOUT: define void @_CF_nested_tuple.Main(ptr sret({ { i32, i32 }, { i32, i32 } }) %return, ptr %a) !dbg !35 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: call void @_CF.Main.73a97bc8c9926cb5(ptr %return, ptr %a), !dbg !36
// CHECK:STDOUT: call void @_CF.Main.373a8775794c641a(ptr %return, ptr %a), !dbg !36
// CHECK:STDOUT: ret void, !dbg !37
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr i32 @_CF.Main.6a6da5347b4dd84b(i32 %a) !dbg !38 {
// CHECK:STDOUT: define linkonce_odr i32 @_CF.Main.db99c030f99223d6(i32 %a) !dbg !38 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %v.var = alloca i32, align 4, !dbg !39
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %v.var), !dbg !39
@@ -166,7 +166,7 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT: ret i32 %.loc19, !dbg !42
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.287da2429e961b22(ptr sret({ i32, i32 }) %return, ptr %a) !dbg !43 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.eba3dea1578ec8e5(ptr sret({ i32, i32 }) %return, ptr %a) !dbg !43 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %v.var = alloca { i32, i32 }, align 8, !dbg !44
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %v.var), !dbg !44
@@ -175,7 +175,7 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT: ret void, !dbg !47
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.bcfa232a7f7e3dde() !dbg !48 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.af8424a3d0a9008a() !dbg !48 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %v.var = alloca {}, align 8, !dbg !49
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %v.var), !dbg !49
@@ -184,7 +184,7 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT: ret void, !dbg !52
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.fd0a4d4c23847a64(ptr sret({ i32, i32 }) %return, ptr %a) !dbg !53 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.d67e493e33e87aab(ptr sret({ i32, i32 }) %return, ptr %a) !dbg !53 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %v.var = alloca { i32, i32 }, align 8, !dbg !54
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %v.var), !dbg !54
@@ -193,7 +193,7 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT: ret void, !dbg !57
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.73a97bc8c9926cb5(ptr sret({ { i32, i32 }, { i32, i32 } }) %return, ptr %a) !dbg !58 {
// CHECK:STDOUT: define linkonce_odr void @_CF.Main.373a8775794c641a(ptr sret({ { i32, i32 }, { i32, i32 } }) %return, ptr %a) !dbg !58 {
// CHECK:STDOUT: entry:
// CHECK:STDOUT: %v.var = alloca { { i32, i32 }, { i32, i32 } }, align 8, !dbg !59
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %v.var), !dbg !59
@@ -251,27 +251,27 @@ fn F_nested_tuple(a: ((i32, i32), X)) -> ((i32, i32), X) {
// CHECK:STDOUT: !35 = distinct !DISubprogram(name: "F_nested_tuple", linkageName: "_CF_nested_tuple.Main", scope: null, file: !3, line: 73, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !36 = !DILocation(line: 74, column: 10, scope: !35)
// CHECK:STDOUT: !37 = !DILocation(line: 74, column: 3, scope: !35)
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.6a6da5347b4dd84b", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.db99c030f99223d6", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !39 = !DILocation(line: 18, column: 3, scope: !38)
// CHECK:STDOUT: !40 = !DILocation(line: 18, column: 14, scope: !38)
// CHECK:STDOUT: !41 = !DILocation(line: 19, column: 10, scope: !38)
// CHECK:STDOUT: !42 = !DILocation(line: 19, column: 3, scope: !38)
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.287da2429e961b22", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.eba3dea1578ec8e5", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !44 = !DILocation(line: 18, column: 3, scope: !43)
// CHECK:STDOUT: !45 = !DILocation(line: 18, column: 14, scope: !43)
// CHECK:STDOUT: !46 = !DILocation(line: 19, column: 10, scope: !43)
// CHECK:STDOUT: !47 = !DILocation(line: 19, column: 3, scope: !43)
// CHECK:STDOUT: !48 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.bcfa232a7f7e3dde", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !48 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.af8424a3d0a9008a", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !49 = !DILocation(line: 18, column: 3, scope: !48)
// CHECK:STDOUT: !50 = !DILocation(line: 18, column: 14, scope: !48)
// CHECK:STDOUT: !51 = !DILocation(line: 19, column: 10, scope: !48)
// CHECK:STDOUT: !52 = !DILocation(line: 19, column: 3, scope: !48)
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.fd0a4d4c23847a64", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.d67e493e33e87aab", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !54 = !DILocation(line: 18, column: 3, scope: !53)
// CHECK:STDOUT: !55 = !DILocation(line: 18, column: 14, scope: !53)
// CHECK:STDOUT: !56 = !DILocation(line: 19, column: 10, scope: !53)
// CHECK:STDOUT: !57 = !DILocation(line: 19, column: 3, scope: !53)
// CHECK:STDOUT: !58 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.73a97bc8c9926cb5", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !58 = distinct !DISubprogram(name: "F", linkageName: "_CF.Main.373a8775794c641a", scope: null, file: !3, line: 17, type: !5, spFlags: DISPFlagDefinition, unit: !2)
// CHECK:STDOUT: !59 = !DILocation(line: 18, column: 3, scope: !58)
// CHECK:STDOUT: !60 = !DILocation(line: 18, column: 14, scope: !58)
// CHECK:STDOUT: !61 = !DILocation(line: 19, column: 10, scope: !58)