[llvm] [RISCV][GlobalISel] Legalize Scalable Vector Loads (PR #84965)

Jiahan Xie via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 25 12:54:54 PDT 2024


================
@@ -220,7 +220,8 @@ struct TypePairAndMemDesc {
            Align >= Other.Align &&
            // FIXME: This perhaps should be stricter, but the current legality
            // rules are written only considering the size.
-           MemTy.getSizeInBits() == Other.MemTy.getSizeInBits();
----------------
jiahanxie353 wrote:

Right, `(ElementCount::Scalable(2), 8) != (ElementCount::Fixed(1), 8)`, but does that mean they are incompatible? 
Since `(ElementCount::Scalable(2), 8)` can hold at least two `s8` types, it'll definitely be a multiple of `(ElementCount::Fixed(1), 8)`. So it seems to me `(ElementCount::Scalable(2), 8)` can hold/be "compatible" with `(ElementCount::Fixed(1), 8)`, if it makes sense.

https://github.com/llvm/llvm-project/pull/84965


More information about the llvm-commits mailing list