@@ -681,4 +681,45 @@ bb2:
681
681
bb3:
682
682
%9999 = tuple ()
683
683
return %9999 : $()
684
- }
684
+ }
685
+
686
+ // CHECK-LABEL: begin running test 1 of 1 on alloc_stack_inline_array_sendable: sil_regionanalysis_underlying_tracked_value with: @trace[0]
687
+ // CHECK: TrackableValue. State: TrackableValueState[id: 0][is_no_alias: no][is_sendable: yes][region_value_kind: disconnected].
688
+ // CHECK: Rep Value: %2 = vector_base_addr %1
689
+ // CHECK: end running test 1 of 1 on alloc_stack_inline_array_sendable: sil_regionanalysis_underlying_tracked_value with: @trace[0]
690
+ sil [ossa] @alloc_stack_inline_array_sendable : $@convention(thin) () -> () {
691
+ bb0:
692
+ specify_test "sil_regionanalysis_underlying_tracked_value @trace[0]"
693
+ %0 = alloc_stack $InlineArray<1, UInt8>
694
+ %1 = struct_element_addr %0: $*InlineArray<1, UInt8>, #InlineArray._storage
695
+ %2 = vector_base_addr %1 : $*Builtin.FixedArray<1, UInt8>
696
+ %3 = integer_literal $Builtin.Int8, 0
697
+ %4 = struct $UInt8 (%3)
698
+ store %4 to [trivial] %2
699
+ %6 = load [trivial] %0
700
+ dealloc_stack %0
701
+ debug_value [trace] %2
702
+
703
+ %7 = tuple ()
704
+ return %7 : $()
705
+ }
706
+
707
+ // CHECK-LABEL: begin running test 1 of 1 on alloc_stack_inline_array_nonsendable: sil_regionanalysis_underlying_tracked_value with: @trace[0]
708
+ // CHECK: TrackableValue. State: TrackableValueState[id: 0][is_no_alias: yes][is_sendable: no][region_value_kind: disconnected].
709
+ // CHECK: Rep Value: %1 = alloc_stack $InlineArray
710
+ // CHECK: end running test 1 of 1 on alloc_stack_inline_array_nonsendable: sil_regionanalysis_underlying_tracked_value with: @trace[0]
711
+ sil [ossa] @alloc_stack_inline_array_nonsendable : $@convention(thin) (@owned NonSendableKlass) -> () {
712
+ bb0(%arg : @owned $NonSendableKlass):
713
+ specify_test "sil_regionanalysis_underlying_tracked_value @trace[0]"
714
+ %0 = alloc_stack $InlineArray<1, NonSendableKlass>
715
+ %1 = struct_element_addr %0: $*InlineArray<1, NonSendableKlass>, #InlineArray._storage
716
+ %2 = vector_base_addr %1 : $*Builtin.FixedArray<1, NonSendableKlass>
717
+ store %arg to [init] %2
718
+ %6 = load [take] %0
719
+ destroy_value %6
720
+ dealloc_stack %0
721
+ debug_value [trace] %2
722
+
723
+ %7 = tuple ()
724
+ return %7 : $()
725
+ }
0 commit comments