@@ -145,10 +145,9 @@ class Foo {
145
145
// x86_64 returns an HA of four floats directly in two <2 x float>
146
146
// x86_64-macosx: define hidden swiftcc float @"$s8abitypes3FooC4barc{{[_0-9a-zA-Z]*}}F"(ptr %0, ptr swiftself %1) {{.*}} {
147
147
// x86_64-macosx: load ptr, ptr @"\01L_selector(newRect)", align 8
148
- // x86_64-macosx: [[RESULT:%.*]] = call { <2 x float>, <2 x float> } bitcast (ptr @objc_msgSend
148
+ // x86_64-macosx: [[RESULT:%.*]] = call { <2 x float>, <2 x float> } @objc_msgSend
149
149
// x86_64-macosx: store { <2 x float>, <2 x float> } [[RESULT]]
150
- // x86_64-macosx: [[CAST:%.*]] = bitcast ptr
151
- // x86_64-macosx: load { float, float, float, float }, ptr [[CAST]]
150
+ // x86_64-macosx: load { float, float, float, float }, ptr
152
151
// x86_64-macosx: ret float
153
152
//
154
153
// armv7 returns an HA of four floats indirectly
@@ -174,7 +173,7 @@ class Foo {
174
173
// armv7k returns an HA of four floats directly
175
174
// armv7k-watchos: define hidden swiftcc float @"$s8abitypes3FooC4barc{{[_0-9a-zA-Z]*}}F"(ptr %0, ptr swiftself %1) {{.*}} {
176
175
// armv7k-watchos: load ptr, ptr @"\01L_selector(newRect)", align 4
177
- // armv7k-watchos: [[RESULT:%.*]] = call [[ARMV7K_MYRECT]] bitcast (ptr @objc_msgSend
176
+ // armv7k-watchos: [[RESULT:%.*]] = call [[ARMV7K_MYRECT]] @objc_msgSend
178
177
// armv7k-watchos: store [[ARMV7K_MYRECT]] [[RESULT]]
179
178
// armv7k-watchos: [[CAST:%.*]] = bitcast ptr
180
179
// armv7k-watchos: load { float, float, float, float }, ptr [[CAST]]
@@ -191,7 +190,6 @@ class Foo {
191
190
192
191
// x86_64-macosx: define hidden swiftcc double @"$s8abitypes3FooC4bazc{{[_0-9a-zA-Z]*}}F"(ptr %0, ptr swiftself %1) {{.*}} {
193
192
// x86_64-macosx: load ptr, ptr @"\01L_selector(newTrio)", align 8
194
- // x86_64-macosx: [[CAST:%[0-9]+]] = bitcast ptr %0
195
193
// x86_64-macosx: call void @objc_msgSend_stret
196
194
func bazc( _ p: StructReturns ) -> Double {
197
195
return p. newTrio ( ) . j
@@ -215,13 +213,11 @@ class Foo {
215
213
216
214
// x86_64-macosx: define hidden swiftcc i64 @"$s8abitypes3FooC9getnested{{[_0-9a-zA-Z]*}}F"(ptr %0, ptr swiftself %1) {{.*}} {
217
215
// x86_64-macosx: call i64 @objc_msgSend
218
- // x86_64-macosx: bitcast
219
216
// x86_64-macosx: call void @llvm.lifetime.start
220
217
// x86_64-macosx: store i32 {{.*}}
221
218
// x86_64-macosx: store i32 {{.*}}
222
- // x86_64-macosx: [[T0:%.*]] = getelementptr inbounds { i64 }, { i64 }
219
+ // x86_64-macosx: [[T0:%.*]] = getelementptr inbounds { i64 }, ptr
223
220
// x86_64-macosx: load i64, ptr [[T0]], align 8
224
- // x86_64-macosx: bitcast
225
221
// x86_64-macosx: call void @llvm.lifetime.end
226
222
// x86_64-macosx: ret i64
227
223
func getnested( _ p: StructReturns ) -> NestedInts {
@@ -237,17 +233,15 @@ class Foo {
237
233
}
238
234
239
235
// x86_64-macosx: define internal ptr @"$s8abitypes3FooC9copyProto{{[_0-9a-zA-Z]*}}FTo"(ptr %0, ptr %1, ptr %2) {{[#0-9]*}} {
240
- // x86_64-macosx: [[VALUE:%[0-9]+]] = call swiftcc [[TYPE:%.*]] @"$s8abitypes3FooC9copyProto{{[_0-9a-zA-Z]*}}F"
241
- // x86_64-macosx: [[RESULT:%[0-9]+]] = bitcast [[TYPE:%.*]] [[VALUE]] to ptr
242
- // x86_64-macosx: ret ptr [[RESULT]]
236
+ // x86_64-macosx: [[VALUE:%[0-9]+]] = call swiftcc ptr @"$s8abitypes3FooC9copyProto{{[_0-9a-zA-Z]*}}F"
237
+ // x86_64-macosx: ret ptr [[VALUE]]
243
238
@objc dynamic func copyProto( _ a: AnyObject ) -> AnyObject {
244
239
return a
245
240
}
246
241
247
242
// x86_64-macosx: define internal ptr @"$s8abitypes3FooC13copyProtoComp{{[_0-9a-zA-Z]*}}FTo"(ptr %0, ptr %1, ptr %2) {{[#0-9]*}} {
248
- // x86_64-macosx: [[VALUE:%[0-9]+]] = call swiftcc [[TYPE:%.*]] @"$s8abitypes3FooC13copyProtoComp{{[_0-9a-zA-Z]*}}F"
249
- // x86_64-macosx: [[RESULT:%[0-9]+]] = bitcast [[TYPE]] [[VALUE]] to ptr
250
- // x86_64-macosx: ret ptr [[RESULT]]
243
+ // x86_64-macosx: [[VALUE:%[0-9]+]] = call swiftcc ptr @"$s8abitypes3FooC13copyProtoComp{{[_0-9a-zA-Z]*}}F"
244
+ // x86_64-macosx: ret ptr [[VALUE]]
251
245
@objc dynamic func copyProtoComp( _ a: P1 & P2 ) -> P1 & P2 {
252
246
return a
253
247
}
0 commit comments