You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
%load.1.16 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.1.16, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
21
-
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.1.16, ptrnonnull%gep.arr.16, i321, <vscale x 4 x i1> %mask)
19
+
%load.0.16 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.16, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
20
+
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.16, ptrnonnull%gep.arr.16, i321, <vscale x 4 x i1> %mask)
22
21
23
-
%load.1.32 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.1.32, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
24
-
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.1.32, ptrnonnull%gep.arr.32, i321, <vscale x 4 x i1> %mask)
22
+
%load.0.32 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.32, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
23
+
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.32, ptrnonnull%gep.arr.32, i321, <vscale x 4 x i1> %mask)
25
24
26
-
%load.1.48 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.1.48, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
27
-
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.1.48, ptrnonnull%gep.arr.48, i321, <vscale x 4 x i1> %mask)
25
+
%load.0.48 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.48, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
26
+
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.48, ptrnonnull%gep.arr.48, i321, <vscale x 4 x i1> %mask)
28
27
29
28
%faddop0 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.arr.16, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
30
29
%faddop1 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.arr.48, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
@@ -33,6 +32,39 @@ define <vscale x 4 x float> @dead_scalable_store(i32 %0, ptr %1) {
33
32
ret <vscale x 4 x float> %fadd
34
33
}
35
34
35
+
define <4 x float> @dead_scalable_store_fixed(ptr%0) {
36
+
; CHECK-LABEL: define <4 x float> @dead_scalable_store_fixed(
37
+
; CHECK: call void @llvm.masked.store.v4f32.p0(<4 x float> %load.0.16, ptr nonnull %gep.arr.16, i32 1, <4 x i1> %mask)
38
+
; CHECK-NOT: call void @llvm.masked.store.v4f32.p0(<4 x float> %load.0.32, ptr nonnull %gep.arr.36, i32 1, <4 x i1> %mask2)
39
+
; CHECK: call void @llvm.masked.store.v4f32.p0(<4 x float> %load.0.48, ptr nonnull %gep.arr.48, i32 1, <4 x i1> %mask)
40
+
;
41
+
%arr = alloca [64 x i32], align4
42
+
%mask = call <4 x i1> @llvm.get.active.lane.mask.v4i1.i32(i320, i324)
43
+
%mask2 = call <4 x i1> @llvm.get.active.lane.mask.v4i1.i32(i320, i323)
%load.0.16 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.16, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
84
+
%load.0.16 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.16, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
53
85
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.16, ptrnonnull%gep.arr.16, i321, <vscale x 4 x i1> %mask)
54
86
55
-
%load.0.30 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.30, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
87
+
%load.0.30 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.30, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
56
88
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.30, ptrnonnull%gep.arr.30, i321, <vscale x 4 x i1> %mask)
57
89
58
-
%load.0.48 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.48, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
90
+
%load.0.48 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.48, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
59
91
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.48, ptrnonnull%gep.arr.48, i321, <vscale x 4 x i1> %mask)
60
92
61
93
%faddop0 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.arr.16, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
@@ -80,13 +112,13 @@ define <vscale x 4 x float> @dead_scalable_store_small_mask(ptr %0) {
%load.0.16 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.16, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
115
+
%load.0.16 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.16, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
84
116
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.16, ptrnonnull%gep.arr.16, i321, <vscale x 4 x i1> %mask)
85
117
86
-
%load.0.30 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.30, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
118
+
%load.0.30 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.30, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
87
119
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.30, ptrnonnull%gep.arr.30, i321, <vscale x 4 x i1> %mask)
88
120
89
-
%load.0.46 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.46, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
121
+
%load.0.46 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%gep.0.46, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
90
122
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0.46, ptrnonnull%gep.arr.46, i321, <vscale x 4 x i1> %mask)
91
123
92
124
%smallmask = call <vscale x 4 x i1> @llvm.get.active.lane.mask.nxv4i1.32(i320, i322)
@@ -101,7 +133,7 @@ define <vscale x 4 x float> @dead_scalar_store(ptr noalias %0, ptr %1) {
101
133
; CHECK-LABEL: define <vscale x 4 x float> @dead_scalar_store(
102
134
; CHECK-NOT: store i32 20, ptr %gep.1.12
103
135
;
104
-
%mask = call <vscale x 4 x i1> @llvm.get.active.lane.mask.nxv4i1.i32(i320, i324)
136
+
%mask = call <vscale x 4 x i1> @llvm.get.active.lane.mask.nxv4i1.i128(i1280, i1284)
%load.0 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%0, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
176
+
%load.0 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%0, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
125
177
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0, ptrnonnull%1, i321, <vscale x 4 x i1> %mask)
126
178
%retval = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%1, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
127
179
ret <vscale x 4 x float> %retval
128
180
}
129
181
130
-
; Don't do anything if the 2nd Op of get active lane mask is 0. This currently generates poison
131
-
define <vscale x 4 x float> @mask_hi_0(ptrnoalias%0, ptr%1) {
132
-
; CHECK-LABEL: define <vscale x 4 x float> @mask_hi_0(
182
+
; Don't do anything if the mask's Op1 < Op0
183
+
define <vscale x 4 x float> @active_lane_mask_lt(ptrnoalias%0, ptr%1) {
184
+
; CHECK-LABEL: define <vscale x 4 x float> @active_lane_mask_lt(
133
185
; CHECK: store i32 20, ptr %1
134
186
;
135
-
%mask = call <vscale x 4 x i1> @llvm.get.active.lane.mask.nxv4i1.i32(i320, i320)
187
+
%mask = call <vscale x 4 x i1> @llvm.get.active.lane.mask.nxv4i1.i32(i324, i322)
136
188
storei3220, ptr%1
137
189
138
-
%load.0 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%0, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
190
+
%load.0 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%0, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
139
191
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0, ptrnonnull%1, i321, <vscale x 4 x i1> %mask)
140
192
%retval = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%1, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
141
193
ret <vscale x 4 x float> %retval
142
194
}
143
195
144
-
; Don't do anything if the 2nd Op is gt/eq the 1st
145
-
define <vscale x 4 x float> @active_lane_mask_gt_eq(ptrnoalias%0, ptr%1) {
146
-
; CHECK-LABEL: define <vscale x 4 x float> @active_lane_mask_gt_eq(
196
+
; Don't do anything if the mask's Op1 == Op0
197
+
define <vscale x 4 x float> @active_lane_mask_eq(ptrnoalias%0, ptr%1) {
198
+
; CHECK-LABEL: define <vscale x 4 x float> @active_lane_mask_eq(
147
199
; CHECK: store i32 20, ptr %1
148
200
;
149
-
%mask = call <vscale x 4 x i1> @llvm.get.active.lane.mask.nxv4i1.i32(i324, i322)
201
+
%mask = call <vscale x 4 x i1> @llvm.get.active.lane.mask.nxv4i1.i32(i322, i322)
150
202
storei3220, ptr%1
151
203
152
-
%load.0 = tailcall <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%0, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
204
+
%load.0 = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%0, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
153
205
callvoid@llvm.masked.store.nxv4f32.p0(<vscale x 4 x float> %load.0, ptrnonnull%1, i321, <vscale x 4 x i1> %mask)
154
206
%retval = call <vscale x 4 x float> @llvm.masked.load.nxv4f32.p0(ptrnonnull%1, i321, <vscale x 4 x i1> %mask, <vscale x 4 x float> zeroinitializer)
155
207
ret <vscale x 4 x float> %retval
@@ -164,9 +216,9 @@ define <vscale x 16 x i8> @scalar_stores_small_mask(ptr noalias %0, ptr %1) {
0 commit comments