@@ -62,7 +62,7 @@ bb0(%0 : $Int):
62
62
bb1:
63
63
// Forward reference MRVs.
64
64
store %0 to %6#1 : $*Int // CHECK: store %0 to %6#1
65
- strong_release %6#0 : $Builtin.NativeObject // CHECK: strong_release %6#0
65
+ strong_release %6#0 : $@box Int // CHECK: strong_release %6#0
66
66
67
67
return %5 : $() // CHECK: return %5 : $()
68
68
bb2:
@@ -296,7 +296,7 @@ bb0(%0 : $*Runcible, %1 : $*protocol<Bendable, Runcible>):
296
296
// CHECK: dealloc_stack
297
297
%9 = dealloc_stack %4#0 : $*@local_storage protocol<Bendable, Runcible>
298
298
// CHECK: release
299
- %10 = strong_release %2#0 : $Builtin.NativeObject
299
+ %10 = strong_release %2#0 : $@box protocol<Bendable, Runcible>
300
300
// CHECK: return
301
301
%11 = return %7 : $()
302
302
}
@@ -318,7 +318,7 @@ bb0(%0 : $ClassBound):
318
318
%6 = witness_method $@opened("01234567-89ab-cdef-0123-111111111111") ClassBound, #ClassBound.classBoundMethod!1, %5 : $@opened("01234567-89ab-cdef-0123-111111111111") ClassBound : $@convention(witness_method) <T: ClassBound> (T) -> ()
319
319
%7 = apply %6<@opened("01234567-89ab-cdef-0123-111111111111") ClassBound>(%5) : $@convention(witness_method) <T: ClassBound> (T) -> ()
320
320
%8 = tuple ()
321
- %9 = strong_release %1#0 : $Builtin.NativeObject
321
+ %9 = strong_release %1#0 : $@box ClassBound
322
322
%10 = return %8 : $()
323
323
}
324
324
@@ -362,7 +362,7 @@ bb0(%0 : $@thin Aleph.Type):
362
362
// CHECK: struct_extract {{%.*}} : $Aleph, #Aleph.a
363
363
%15 = struct_extract %14 : $Aleph, #Aleph.a
364
364
%16 = strong_retain %15 : $Ref
365
- %17 = strong_release %2#0 : $Builtin.NativeObject
365
+ %17 = strong_release %2#0 : $@box Aleph
366
366
%18 = return %14 : $Aleph
367
367
}
368
368
@@ -441,7 +441,7 @@ bb0(%0 : $Int, %1 : $Float):
441
441
// CHECK: apply
442
442
%24 = apply %19(%17) : $@convention(thin) (Float) -> ()
443
443
%25 = tuple ()
444
- %26 = strong_release %2#0 : $Builtin.NativeObject
444
+ %26 = strong_release %2#0 : $@box (Int, Float)
445
445
%27 = return %25 : $()
446
446
}
447
447
@@ -465,8 +465,8 @@ bb0(%0 : $Int, %1 : $M):
465
465
%10 = store %6 to %9 : $*Int
466
466
%11 = strong_release %7 : $M
467
467
%12 = tuple ()
468
- %13 = strong_release %4#0 : $Builtin.NativeObject
469
- %14 = strong_release %2#0 : $Builtin.NativeObject
468
+ %13 = strong_release %4#0 : $@box M
469
+ %14 = strong_release %2#0 : $@box Int
470
470
%15 = return %12 : $()
471
471
}
472
472
504
504
br isa(%n : $Builtin.Int1)
505
505
isa(%6 : $Builtin.Int1):
506
506
%7 = strong_release %3 : $B
507
- %8 = strong_release %1#0 : $Builtin.NativeObject
507
+ %8 = strong_release %1#0 : $@box B
508
508
%9 = return %6 : $Builtin.Int1
509
509
}
510
510
@@ -522,8 +522,8 @@ bb0(%0 : $Builtin.RawPointer, %1 : $Builtin.Word):
522
522
%8 = load %3#1 : $*Builtin.Word // CHECK: load
523
523
// CHECK: index_raw_pointer {{%.*}} : $Builtin.RawPointer, {{%.*}} : $Builtin.Word
524
524
%9 = index_raw_pointer %7 : $Builtin.RawPointer, %8 : $Builtin.Word
525
- %10 = strong_release %3#0 : $Builtin.NativeObject
526
- %11 = strong_release %2#0 : $Builtin.NativeObject
525
+ %10 = strong_release %3#0 : $@box Builtin.Word
526
+ %11 = strong_release %2#0 : $@box Builtin.RawPointer
527
527
%12 = return %9 : $Builtin.RawPointer
528
528
}
529
529
@@ -568,8 +568,8 @@ bb0(%0 : $SomeClass, %1 : $SomeSubclass):
568
568
%15 = tuple (%9 : $@thick SomeClass.Type, %14 : $@thick SomeClass.Type) // CHECK: tuple
569
569
%16 = strong_release %11 : $SomeSubclass
570
570
%17 = strong_release %7 : $SomeClass
571
- %18 = strong_release %3#0 : $Builtin.NativeObject
572
- %19 = strong_release %2#0 : $Builtin.NativeObject
571
+ %18 = strong_release %3#0 : $@box SomeSubclass
572
+ %19 = strong_release %2#0 : $@box SomeClass
573
573
%20 = return %15 : $(@thick SomeClass.Type, @thick SomeClass.Type)
574
574
}
575
575
@@ -585,7 +585,7 @@ bb0(%0 : $*T):
585
585
%8 = tuple (%3 : $@thick T.Type, %7 : $@thick T.Type) // CHECK: tuple
586
586
%9 = destroy_addr %5#1 : $*T
587
587
%10 = dealloc_stack %5#0 : $*@local_storage T
588
- %11 = strong_release %1#0 : $Builtin.NativeObject
588
+ %11 = strong_release %1#0 : $@box T
589
589
%12 = return %8 : $(@thick T.Type, @thick T.Type)
590
590
}
591
591
@@ -599,7 +599,7 @@ bb0(%0 : $*SomeProtocol):
599
599
%6 = existential_metatype $@thick SomeProtocol.Type, %4#1 : $*SomeProtocol
600
600
%7 = destroy_addr %4#1 : $*SomeProtocol
601
601
%8 = dealloc_stack %4#0 : $*@local_storage SomeProtocol
602
- %9 = strong_release %1#0 : $Builtin.NativeObject
602
+ %9 = strong_release %1#0 : $@box SomeProtocol
603
603
%10 = return %6 : $@thick SomeProtocol.Type
604
604
}
605
605
@@ -665,8 +665,8 @@ bb0(%0 : $Builtin.Int1, %1 : $Builtin.Int1):
665
665
%9 = load %3#1 : $*Builtin.Int1
666
666
// CHECK: builtin "cmp_eq_Int1"({{%.*}} : $Builtin.Int1, {{%.*}} : $Builtin.Int1) : $Builtin.Int1
667
667
%10 = builtin "cmp_eq_Int1"(%8 : $Builtin.Int1, %9 : $Builtin.Int1) : $Builtin.Int1
668
- strong_release %3#0 : $Builtin.NativeObject
669
- strong_release %2#0 : $Builtin.NativeObject
668
+ strong_release %3#0 : $@box Builtin.Int1
669
+ strong_release %2#0 : $@box Builtin.Int1
670
670
return %10 : $Builtin.Int1
671
671
}
672
672
683
683
sil @test_dealloc_box : $@convention(thin) () -> () {
684
684
bb0:
685
685
%0 = alloc_box $Class1
686
- dealloc_box $Class1, %0#0 : $Builtin.NativeObject
686
+ dealloc_box %0#0 : $@box Class1
687
687
%2 = tuple ()
688
688
return %2 : $()
689
689
}
@@ -692,18 +692,18 @@ bb0:
692
692
693
693
// CHECK-LABEL: closure_test
694
694
sil @takes_closure : $@convention(thin) (@callee_owned () -> ()) -> ()
695
- sil @closure0 : $@convention(thin) (Builtin.NativeObject , @inout Int) -> ()
695
+ sil @closure0 : $@convention(thin) (@box Int , @inout Int) -> ()
696
696
697
697
sil @closure_test : $@convention(thin) () -> () {
698
698
bb0:
699
699
%0 = alloc_box $Int // users: %10, %8, %8, %7, %4
700
700
701
701
%5 = function_ref @takes_closure : $@convention(thin) (@callee_owned () -> ()) -> ()
702
- %6 = function_ref @closure0 : $@convention(thin) (Builtin.NativeObject , @inout Int) -> ()
703
- strong_retain %0#0 : $Builtin.NativeObject
704
- %8 = partial_apply %6(%0#0, %0#1) : $@convention(thin) (Builtin.NativeObject , @inout Int) -> ()
702
+ %6 = function_ref @closure0 : $@convention(thin) (@box Int , @inout Int) -> ()
703
+ strong_retain %0#0 : $@box Int
704
+ %8 = partial_apply %6(%0#0, %0#1) : $@convention(thin) (@box Int , @inout Int) -> ()
705
705
%9 = apply %5(%8) : $@convention(thin) (@callee_owned () -> ()) -> ()
706
- strong_release %0#0 : $Builtin.NativeObject
706
+ strong_release %0#0 : $@box Int
707
707
708
708
%11 = tuple ()
709
709
return %11 : $()
@@ -764,7 +764,7 @@ bb4(%y : $Int):
764
764
bb5:
765
765
%15 = function_ref @_T6switch1cFT_T_ : $@convention(thin) () -> () // CHECK: function_ref
766
766
%16 = apply %15() : $@convention(thin) () -> ()
767
- strong_release %1#0 : $Builtin.NativeObject // CHECK: release
767
+ strong_release %1#0 : $@box MaybePair
768
768
%18 = tuple ()
769
769
return %18 : $() // CHECK: return
770
770
}
@@ -905,7 +905,7 @@ bb0(%0 : $*Bendable, %1 : $Spoon):
905
905
deinit_existential_addr %0 : $*Bendable
906
906
%5 = load %2#1 : $*Spoon
907
907
store %5 to %4 : $*Spoon
908
- strong_release %2#0 : $Builtin.NativeObject
908
+ strong_release %2#0 : $@box Spoon
909
909
%8 = tuple ()
910
910
return %8 : $()
911
911
}
@@ -919,7 +919,7 @@ bb0(%0 : $ConcreteClass):
919
919
strong_retain %3 : $ConcreteClass
920
920
// CHECK: init_existential_ref %{{.*}} : $ConcreteClass : $ConcreteClass, $ClassP
921
921
%5 = init_existential_ref %3 : $ConcreteClass : $ConcreteClass, $ClassP
922
- strong_release %1#0 : $Builtin.NativeObject
922
+ strong_release %1#0 : $@box ConcreteClass
923
923
return %5 : $ClassP
924
924
}
925
925
0 commit comments