[PATCH] D144584: [RISCV][NFC] Reuse getDeinterleaveViaVNSRL to lower deinterleave intrinsics
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 22 14:49:03 PST 2023
craig.topper added inline comments.
================
Comment at: llvm/lib/Target/RISCV/RISCVISelLowering.cpp:3143
+ if (Src.getSimpleValueType().isFixedLengthVector())
+ Src = convertToScalableVector(SrcContainerVT, Src, DAG, Subtarget);
+
----------------
Can this nest in the `if (ContainerVT.isFixedLengthVector())` earlier. The source and destination should alway be both fixed or both scalable.
================
Comment at: llvm/lib/Target/RISCV/RISCVISelLowering.cpp:3147
+ // This also converts FP to int.
+ unsigned EltBits = SrcContainerVT.getScalarSizeInBits();
+ MVT WideSrcContainerVT = MVT::getVectorVT(MVT::getIntegerVT(EltBits * 2), N);
----------------
To do my above suggestion, this would need to use ContainerVT to keep SrcContainerVT isolated to the body of the `if (ContainerVT.isFixedLengthVector())`
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D144584/new/
https://reviews.llvm.org/D144584
More information about the llvm-commits
mailing list