@@ -72,6 +72,43 @@ sil_global @static_array : $TestArrayStorage = {
72
72
}
73
73
// CHECK: @static_array = {{(dllexport )?}}{{(protected )?}}global %T18static_initializer16TestArrayStorageC_tailelems0c { [1 x i64] zeroinitializer, %T18static_initializer16TestArrayStorageC_tailelems0 <{ %swift.refcounted zeroinitializer, %Ts5Int32V <{ i32 2 }>, [4 x i8] undef, %Ts5Int64V <{ i64 10 }>, %Ts5Int64V <{ i64 20 }> }> }, align 8
74
74
75
+ sil_global @static_vector : $Int64 = {
76
+ %0 = integer_literal $Builtin.Int64, 2
77
+ %1 = integer_literal $Builtin.Int64, 10
78
+ %2 = integer_literal $Builtin.Int64, 20
79
+ %3 = struct $Int64 (%0 : $Builtin.Int64)
80
+ %4 = struct $Int64 (%1 : $Builtin.Int64)
81
+ %5 = struct $Int64 (%2 : $Builtin.Int64)
82
+ %initval = vector (%3 : $Int64, %4 : $Int64, %5 : $Int64)
83
+ }
84
+ // CHECK: @static_vector = {{(dllexport )?}}{{(protected )?}}global [3 x %Ts5Int64V] [%Ts5Int64V <{ i64 2 }>, %Ts5Int64V <{ i64 10 }>, %Ts5Int64V <{ i64 20 }>], align 8
85
+
86
+ sil_global @static_optional_int_vector : $Optional<Int32> = {
87
+ %0 = integer_literal $Builtin.Int32, 2
88
+ %1 = integer_literal $Builtin.Int32, 10
89
+ %2 = integer_literal $Builtin.Int32, 20
90
+ %3 = struct $Int32 (%0 : $Builtin.Int32)
91
+ %4 = struct $Int32 (%1 : $Builtin.Int32)
92
+ %5 = struct $Int32 (%2 : $Builtin.Int32)
93
+ %6 = enum $Optional<Int32>, #Optional.some!enumelt, %3 : $Int32
94
+ %7 = enum $Optional<Int32>, #Optional.some!enumelt, %4 : $Int32
95
+ %8 = enum $Optional<Int32>, #Optional.some!enumelt, %5 : $Int32
96
+ %initval = vector (%6 : $Optional<Int32>, %7 : $Optional<Int32>, %8 : $Optional<Int32>)
97
+ }
98
+ // CHECK: @static_optional_int_vector = {{(dllexport )?}}{{(protected )?}}global [3 x <{ i32, i1, i8, i8, i8 }>] [<{ i32, i1, i8, i8, i8 }> <{ i32 2, i1 false, i8 undef, i8 undef, i8 undef }>, <{ i32, i1, i8, i8, i8 }> <{ i32 10, i1 false, i8 undef, i8 undef, i8 undef }>, <{ i32, i1, i8, i8, i8 }> <{ i32 20, i1 false, i8 undef, i8 undef, i8 undef }>], align 4
99
+
100
+ sil_global @static_alloc_vector : $Int64 = {
101
+ %0 = integer_literal $Builtin.Word, 3
102
+ %initval = alloc_vector $Int64, %0 : $Builtin.Word
103
+ }
104
+ // CHECK: @static_alloc_vector = {{(dllexport )?}}{{(protected )?}}global [3 x %Ts5Int64V] zeroinitializer, align 8
105
+
106
+ sil_global @static_alloc_vector_optional : $Int64 = {
107
+ %0 = integer_literal $Builtin.Word, 3
108
+ %initval = alloc_vector $Optional<Int32>, %0 : $Builtin.Word
109
+ }
110
+ // CHECK: @static_alloc_vector_optional = {{(dllexport )?}}{{(protected )?}}global [3 x { %Ts5Int32VSg, [3 x i8] }] zeroinitializer, align 8
111
+
75
112
sil_global @static_aligned_array : $TestArrayStorage = {
76
113
%0 = integer_literal $Builtin.Int32, 2
77
114
%1 = float_literal $Builtin.FPIEEE80, 0x3FFE8000000000000000
0 commit comments