1
1
// RUN: %target-swift-frontend -emit-ir %s -swift-version 5 -disable-availability-checking -enable-parameterized-existential-types | %IRGenFileCheck %s
2
2
3
- // REQUIRES: rdar91669918
4
-
5
3
// CHECK-LABEL: @"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq" = linkonce_odr hidden constant
6
4
// CHECK-SAME: { i32 {{.*}}sub ([[INT]] ptrtoint (i8** @{{[0-9]+}} to [[INT]])
7
5
// CHECK-SAME: [16 x i8] c"2\C6\0A\EA>\EE/`\DBphz\CB\FA7\8E",
@@ -53,7 +51,7 @@ public func testConcrete() -> Any.Type {
53
51
// CHECK: [[T0:%.*]] = getelementptr inbounds [1 x i8*], [1 x i8*]* [[ARGS]], i32 0, i32 0
54
52
// CHECK: store i8* bitcast (%swift.type* @"$sSiN" to i8*), i8** [[T0]], align
55
53
// CHECK: [[T0:%.*]] = bitcast [1 x i8*]* [[ARGS]] to i8**
56
- // CHECK: [[CALL:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq" to i8*), i8** [[T0]])
54
+ // CHECK: [[CALL:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq{{(\.ptrauth)?}} " to i8*), i8** [[T0]])
57
55
// CHECK: store atomic %swift.type* [[CALL]], %swift.type** @"$s26existential_shape_metadata2Q0_pySiXPML" release, align
58
56
// CHECK: br label %[[CONT]]
59
57
// CHECK: [[CONT]]:
@@ -70,7 +68,7 @@ public func testDependent<T>(t: T.Type) -> Any.Type {
70
68
// CHECK: [[T1:%.*]] = bitcast %swift.type* %T to i8*
71
69
// CHECK: store i8* [[T1]], i8** [[T0]], align
72
70
// CHECK: [[T0:%.*]] = bitcast [1 x i8*]* [[ARGS]] to i8**
73
- // CHECK: [[METADATA:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq" to i8*), i8** [[T0]])
71
+ // CHECK: [[METADATA:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq{{(\.ptrauth)?}} " to i8*), i8** [[T0]])
74
72
// CHECK: ret %swift.type* [[METADATA]]
75
73
return ( any Q0 < T > ) . self
76
74
}
@@ -85,7 +83,7 @@ public func testComplexApplication<T>(t: T.Type) -> Any.Type {
85
83
// CHECK: [[T1:%.*]] = bitcast %swift.type* [[B_T]] to i8*
86
84
// CHECK: store i8* [[T1]], i8** [[T0]], align
87
85
// CHECK: [[T0:%.*]] = bitcast [1 x i8*]* [[ARGS]] to i8**
88
- // CHECK: [[METADATA:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq" to i8*), i8** [[T0]])
86
+ // CHECK: [[METADATA:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq{{(\.ptrauth)?}} " to i8*), i8** [[T0]])
89
87
// CHECK: ret %swift.type* [[METADATA]]
90
88
return ( any Q0 < B < T > > ) . self
91
89
}
@@ -99,7 +97,7 @@ public func test_private<T>(t: T.Type) -> Any.Type {
99
97
// CHECK: store i8* [[T1]], i8** [[T0]], align
100
98
// CHECK: [[T0:%.*]] = bitcast [1 x i8*]* [[ARGS]] to i8**
101
99
// FIXME: this should be unique?
102
- // CHECK: [[METADATA:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata_unique({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2R033_881A0B6978EB4286E7CFF1E27030ACACLLRd__llXGo" to i8*), i8** [[T0]])
100
+ // CHECK: [[METADATA:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata_unique({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2R033_881A0B6978EB4286E7CFF1E27030ACACLLRd__llXGo{{(\.ptrauth)?}} " to i8*), i8** [[T0]])
103
101
// CHECK: ret %swift.type* [[METADATA]]
104
102
return ( any R0 < T > ) . self
105
103
}
@@ -121,4 +119,4 @@ public func test_privateApplication<T>(t: T.Type) -> Any.Type {
121
119
// CHECK: [[T0:%.*]] = getelementptr inbounds [1 x i8*], [1 x i8*]* [[ARGS]], i32 0, i32 0
122
120
// CHECK: store i8* {{.*}}"$s26existential_shape_metadata1C33_881A0B6978EB4286E7CFF1E27030ACACLLVMf"{{.*}}, i8** [[T0]], align
123
121
// CHECK: [[T0:%.*]] = bitcast [1 x i8*]* [[ARGS]] to i8**
124
- // CHECK: [[METADATA:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq" to i8*), i8** [[T0]])
122
+ // CHECK: [[METADATA:%.*]] = call %swift.type* @swift_getExtendedExistentialTypeMetadata({{.*}}@"$s1TQyd__Rsz26existential_shape_metadata2Q0Rd__llXGoMq{{(\.ptrauth)?}} " to i8*), i8** [[T0]])
0 commit comments