File tree 2 files changed +21
-0
lines changed
2 files changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -3574,6 +3574,7 @@ void LargeLoadableHeuristic::propagate(PostOrderFunctionInfo &po) {
3574
3574
for (auto *BB : po.getPostOrder ()) {
3575
3575
for (auto &I : llvm::reverse (*BB)) {
3576
3576
switch (I.getKind ()) {
3577
+ case SILInstructionKind::UncheckedBitwiseCastInst:
3577
3578
case SILInstructionKind::TupleExtractInst:
3578
3579
case SILInstructionKind::StructExtractInst: {
3579
3580
auto &proj = cast<SingleValueInstruction>(I);
Original file line number Diff line number Diff line change @@ -425,3 +425,23 @@ bb0(%0 : $member_id_t):
425
425
%13 = tuple ()
426
426
return %13 : $()
427
427
}
428
+
429
+ struct Z {
430
+ var r: String
431
+ var p: X
432
+ }
433
+
434
+ // CHECK: sil @test17 : $@convention(thin) (@owned String) -> () {
435
+ // CHECK: bb0(%0 : $String):
436
+ // CHECK: [[T0:%.*]] = alloc_stack $String
437
+ // CHECK: store %0 to [[T0]] : $*String
438
+ // CHECK: [[T1:%.*]] = unchecked_addr_cast [[T0]] : $*String to $*Z
439
+ // CHECK: release_value_addr [[T1]] : $*Z
440
+
441
+ sil @test17: $@convention(thin) (@owned String) -> () {
442
+ bb0(%0 : $String):
443
+ %1 = unchecked_bitwise_cast %0 : $String to $Z
444
+ release_value %1 : $Z
445
+ %13 = tuple ()
446
+ return %13 : $()
447
+ }
You can’t perform that action at this time.
0 commit comments