[SLP] remove redundant size check; NFC

We bail out on small array size anyway.
This commit is contained in:
Sanjay Patel 2020-09-16 08:11:19 -04:00
parent bbad998bab
commit 0cee1bf5d1
1 changed files with 3 additions and 7 deletions

View File

@ -6796,14 +6796,10 @@ public:
return true; return true;
} }
/// Attempt to vectorize the tree found by /// Attempt to vectorize the tree found by matchAssociativeReduction.
/// matchAssociativeReduction.
bool tryToReduce(BoUpSLP &V, TargetTransformInfo *TTI) { bool tryToReduce(BoUpSLP &V, TargetTransformInfo *TTI) {
if (ReducedVals.empty()) // If there are a sufficient number of reduction values, reduce
return false; // to a nearby power-of-2. We can safely generate oversized
// If there is a sufficient number of reduction values, reduce
// to a nearby power-of-2. Can safely generate oversized
// vectors and rely on the backend to split them to legal sizes. // vectors and rely on the backend to split them to legal sizes.
unsigned NumReducedVals = ReducedVals.size(); unsigned NumReducedVals = ReducedVals.size();
if (NumReducedVals < 4) if (NumReducedVals < 4)