This is a follow up to D151468 which added the vslide1down case as a sub-case of vslide1down matching. This generalizes that code into generic mask matching - specifically to point out the sub-vector insert restriction in the original patch. Since the matching logic is basically the same, go ahead and support vslide1up at the same time.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
Other than Craig's comments LGTM
llvm/lib/Target/RISCV/RISCVISelLowering.cpp | ||
---|---|---|
3769–3770 | Out of curiosity, what happens if we remove the restriction that it must be a splat and extract out the scalar like vslide1down v2, (extract_vector_elt v1, idx)? | |
3778 | Nit, extra space | |
3785 | Nit, other places in RISCVISelLowering.cpp spell it VSlidedown |
I think VECTOR_SHUFFLE nodes already required the VTs to match.