Skip to content

Commit 4aa9335

Browse files
committed
exclude v1i64
1 parent 429b79b commit 4aa9335

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

llvm/lib/Target/AArch64/AArch64ISelLowering.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9800,7 +9800,8 @@ SDValue AArch64TargetLowering::LowerCTPOP_PARITY(SDValue Op,
98009800
Val = DAG.getBitcast(VT8Bit, Val);
98019801
Val = DAG.getNode(ISD::CTPOP, DL, VT8Bit, Val);
98029802

9803-
if (Subtarget->hasDotProd() && VT.getScalarSizeInBits() != 16) {
9803+
if (Subtarget->hasDotProd() && VT.getScalarSizeInBits() != 16 &&
9804+
VT.getVectorNumElements() >= 2) {
98049805
EVT DT = VT == MVT::v2i64 ? MVT::v4i32 : VT;
98059806
SDValue Zeros = DAG.getSplatBuildVector(
98069807
DT, DL, DAG.getConstant(0, DL, DT.getScalarType()));
@@ -9820,6 +9821,7 @@ SDValue AArch64TargetLowering::LowerCTPOP_PARITY(SDValue Op,
98209821

98219822
return Val;
98229823
}
9824+
98239825
// Widen v8i8/v16i8 CTPOP result to VT by repeatedly widening pairwise adds.
98249826
unsigned EltSize = 8;
98259827
unsigned NumElts = VT.is64BitVector() ? 8 : 16;

0 commit comments

Comments
 (0)