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
[SelectionDAG][RISCV] Add support for splitting vp.splice (#145184)
Use a stack based expansion similar to the non-VP splice.
This code has been in our downstream for a while. I don't know how often
it is exercised though. Our downstream was missing clipping for the
immediate value to keep it in range of the stack object so I've added
it.
Copy file name to clipboardExpand all lines: llvm/test/CodeGen/RISCV/rvv/vp-splice.ll
+141Lines changed: 141 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -286,3 +286,144 @@ define <vscale x 2 x float> @test_vp_splice_nxv2f32_masked(<vscale x 2 x float>
286
286
%v = call <vscale x 2 x float> @llvm.experimental.vp.splice.nxv2f32(<vscale x 2 x float> %va, <vscale x 2 x float> %vb, i325, <vscale x 2 x i1> %mask, i32%evla, i32%evlb)
287
287
ret <vscale x 2 x float> %v
288
288
}
289
+
290
+
define <vscale x 16 x i64> @test_vp_splice_nxv16i64(<vscale x 16 x i64> %va, <vscale x 16 x i64> %vb, i32zeroext%evla, i32zeroext%evlb) nounwind {
%v = call <vscale x 16 x i64> @llvm.experimental.vp.splice.nxv16i64(<vscale x 16 x i64> %va, <vscale x 16 x i64> %vb, i325, <vscale x 16 x i1> splat (i11), i32%evla, i32%evlb)
355
+
ret <vscale x 16 x i64> %v
356
+
}
357
+
358
+
define <vscale x 16 x i64> @test_vp_splice_nxv16i64_negative_offset(<vscale x 16 x i64> %va, <vscale x 16 x i64> %vb, i32zeroext%evla, i32zeroext%evlb) nounwind {
%v = call <vscale x 16 x i64> @llvm.experimental.vp.splice.nxv16i64(<vscale x 16 x i64> %va, <vscale x 16 x i64> %vb, i32 -1, <vscale x 16 x i1> splat (i11), i32%evla, i32%evlb)
0 commit comments