///
/// Looks for accesses like "a[i * StrideA]" where "StrideA" is loop
/// invariant.
- void collectStridedAcccess(Value *LoadOrStoreInst);
+ void collectStridedAccess(Value *LoadOrStoreInst);
/// Report an analysis message to assist the user in diagnosing loops that are
/// not vectorized.
return false;
}
- // We only allow if-converted PHIs with more than two incoming values.
+ // We only allow if-converted PHIs with exactly two incoming values.
if (Phi->getNumIncomingValues() != 2) {
emitAnalysis(Report(it)
<< "control flow not understood by vectorizer");
return false;
}
if (EnableMemAccessVersioning)
- collectStridedAcccess(ST);
+ collectStridedAccess(ST);
}
if (EnableMemAccessVersioning)
if (LoadInst *LI = dyn_cast<LoadInst>(it))
- collectStridedAcccess(LI);
+ collectStridedAccess(LI);
// Reduction instructions are allowed to have exit users.
// All other instructions must not have external users.
return Stride;
}
-void LoopVectorizationLegality::collectStridedAcccess(Value *MemAccess) {
+void LoopVectorizationLegality::collectStridedAccess(Value *MemAccess) {
Value *Ptr = nullptr;
if (LoadInst *LI = dyn_cast<LoadInst>(MemAccess))
Ptr = LI->getPointerOperand();