This is an archive of the discontinued LLVM Phabricator instance.

[RISCV][NFC] Add tests for interleaved accesses in loop vectorizer
ClosedPublic

Authored by luke on Mar 9 2023, 8:19 AM.

Diff Detail

Event Timeline

luke created this revision.Mar 9 2023, 8:19 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 9 2023, 8:19 AM
luke requested review of this revision.Mar 9 2023, 8:19 AM
reames accepted this revision.Mar 9 2023, 8:28 AM

LGTM

llvm/test/Transforms/LoopVectorize/RISCV/interleaved-accesses-zve32x.ll
33

OT - This example is sort of interesting as the optimal lowering for it probably uses a predicated add, not an interleave at all. Most of your examples fall into this bucket. Doesn't mean we shouldn't do the interleave work, just an observation. Maybe something for the future if we see these patterns in real code?

This revision is now accepted and ready to land.Mar 9 2023, 8:28 AM
luke added inline comments.Mar 9 2023, 8:39 AM
llvm/test/Transforms/LoopVectorize/RISCV/interleaved-accesses-zve32x.ll
33

Good catch. The adds were sprinkled in so I could pipe this into llc and see what code it generates without worrying about DCE.