[llvm] [AArch64][SVE] - Fix crash Possible incorrect use of EVT::getVectorNumElements(). (PR #218733)
David Sherwood via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 25 10:46:39 PDT 2026
================
@@ -4712,7 +4712,7 @@ SDValue DAGCombiner::visitSUBSAT(SDNode *N) {
// Narrow a vXiN USUBSAT to a smaller type when both operands are known
// to fit in fewer bits. This allows targets with native narrow USUBSAT
// (e.g. vpsubusb/vpsubusw) to avoid emulation with vpmaxu + vsub.
- if (!IsSigned && VT.isVector() && VT.isSimple()) {
+ if (!IsSigned && VT.isFixedLengthVector() && VT.isSimple()) {
----------------
david-arm wrote:
It's a shame this has to bail out for scalable vectors, but looking at the `computeKnownBits` call below it's unlikely to work I think.
https://github.com/llvm/llvm-project/pull/218733
More information about the llvm-commits
mailing list