[RISCV] Don't scalarize vector stores if volatile
authorLuke Lau <luke@igalia.com>
Thu, 25 May 2023 21:16:45 +0000 (22:16 +0100)
committerLuke Lau <luke@igalia.com>
Fri, 26 May 2023 08:34:34 +0000 (09:34 +0100)
commit90c4db4a2ce6b0425dc76dcbdd06b32f52c81792
tree70ca4f33e52adee0dc59606e97876c8ba596c51e
parent68f58812e3e99e31d77c0c23b6298489444dc0be
[RISCV] Don't scalarize vector stores if volatile

As noted by @reames in https://reviews.llvm.org/D151211#4373404, we shouldn't
scalarize vector stores of constants if the store is volatile, or vector copies
if either the store or load are volatile.

Reviewed By: reames

Differential Revision: https://reviews.llvm.org/D151500
llvm/lib/Target/RISCV/RISCVISelLowering.cpp
llvm/test/CodeGen/RISCV/rvv/fixed-vectors-load-store.ll
llvm/test/CodeGen/RISCV/rvv/fixed-vectors-store.ll