Skip to content

Commit bce8343

Browse files
committed
Use getVectorNumElements
1 parent 7cc50b0 commit bce8343

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

llvm/lib/Target/RISCV/RISCVISelLowering.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11148,8 +11148,7 @@ SDValue RISCVTargetLowering::lowerMaskedLoad(SDValue Op,
1114811148

1114911149
// If index vector is an i8 vector and the element count exceeds 256, we
1115011150
// should change the element type of index vector to i16 to avoid overflow.
11151-
if (IndexEltVT == MVT::i8 &&
11152-
VT.getVectorElementCount().getKnownMinValue() > 256) {
11151+
if (IndexEltVT == MVT::i8 && VT.getVectorNumElements() > 256) {
1115311152
// FIXME: We need to do vector splitting manually for LMUL=8 cases.
1115411153
if (getLMUL(IndexVT) == RISCVII::LMUL_8)
1115511154
return SDValue();

0 commit comments

Comments
 (0)