Noticed this while looking at some SLP output. If we have an extractelement, we're probably using a slidedown into an destination with no contents. Given this, we can allow the slideup to use a larger VL and clobber tail elements of the destination vector. Doing this allows us to avoid vsetvli toggles in many fixed length vector examples.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Left a very minor stylistic comment. LGTM for what it's worth, but this needs a review from someone more active in the RVV space.
llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp | ||
---|---|---|
836 | Would it be better to change this to case LMUL_RESERVED: llvm_unreachable("reserved LMUL value") so -Wswitch will pick up if the enumeration is expanded. |
Hi all,
we were observing errors when running the llvm testsuitw with -march=rv64gcv. git bisect pointed to this change.
Failed Tests (2): test-suite :: SingleSource/UnitTests/Vector/Vector-constpool.test test-suite :: SingleSource/UnitTests/matrix-types-spec.test
Can anyone else reproduce this?
I can reproduce a failure, haven't yet confirmed this patch is guilty due to annoying cross build headaches. Investigating now, will either revert or fix today.
I think this is now fixed, but my cross build environment for test-suite is a giant collection of hacks. Confirmation that this now works end to end would be appreciated.
Confirmed these two tests are now back to green. Thanks again for the prompt fix @reames.
Would it be better to change this to case LMUL_RESERVED: llvm_unreachable("reserved LMUL value") so -Wswitch will pick up if the enumeration is expanded.