aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorLuke Lau <luke@igalia.com>2024-02-23 14:34:57 +0800
committerLuke Lau <luke@igalia.com>2024-02-23 14:39:16 +0800
commitd7a28f7ad77504694ad8bdc6b2aaa8938f08fbdd (patch)
tree7a57b046d4d88d50d06d9245f8b539343f506a47 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parent850dde063b7f70bb592723064385e9f9ad39c96e (diff)
downloadllvm-d7a28f7ad77504694ad8bdc6b2aaa8938f08fbdd.zip
llvm-d7a28f7ad77504694ad8bdc6b2aaa8938f08fbdd.tar.gz
llvm-d7a28f7ad77504694ad8bdc6b2aaa8938f08fbdd.tar.bz2
[RISCV] Add asserts for insert/extract_subvector invariants. NFC
We can currently select insert_subvector and extract_subvector nodes in RISCVISelDAGToDAG (this is after custom legalizing in RISCVISelLowering) with fixed subvector types. However decomposeSubvectorInsertExtractToSubRegs is based off of scalable subvectors where the indices are scaled by vscale, so any index other than 0 will be wrong. For insert_subvector the vector being inserted into needs to be undef as well, because it assumes we can replace a whole subregister which isn't always the case for fixed subvectors (e.g. insert <2 x i32> into <4 x i32> at index 0 with vlen=128). We currently maintain these invariants in RISCVISelLowering, so this adds asserts in RISCVISelDAGToDAG so we don't break them.
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions