[llvm] [LLVM] Add `llvm.masked.compress` intrinsic (PR #92289)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Thu May 23 10:20:30 PDT 2024
================
@@ -7197,6 +7200,47 @@ SDValue SelectionDAG::getNode(unsigned Opcode, const SDLoc &DL, EVT VT,
return N1.getOperand(1);
break;
}
+ case ISD::MCOMPRESS: {
+ EVT VecVT = N1.getValueType();
+ [[maybe_unused]] EVT MaskVT = N2.getValueType();
+ assert(VT == VecVT && "Vector and result type don't match.");
+ assert(VecVT.isVector() && MaskVT.isVector() &&
+ "Both inputs must be vectors.");
+ assert(VecVT.isScalableVector() == MaskVT.isScalableVector() &&
----------------
topperc wrote:
This should be covered by the getVectorElementCount() check. Element count includes whether the vector is scalable.
https://github.com/llvm/llvm-project/pull/92289
More information about the llvm-commits
mailing list