[llvm] [VPlan] Model address separately. (PR #72164)

via llvm-commits llvm-commits at lists.llvm.org
Sun Dec 17 13:44:05 PST 2023


================
@@ -8174,13 +8174,22 @@ VPRecipeBase *VPRecipeBuilder::tryToWidenMemory(Instruction *I,
   bool Consecutive =
       Reverse || Decision == LoopVectorizationCostModel::CM_Widen;
 
+  VPValue *Ptr = isa<LoadInst>(I) ? Operands[0] : Operands[1];
+  if (Decision != LoopVectorizationCostModel::CM_GatherScatter &&
+      Decision != LoopVectorizationCostModel::CM_Interleave) {
----------------
ayalz wrote:

Check instead if Consecutive? I.e., if Decision is Widen or Widen_Reverse.

https://github.com/llvm/llvm-project/pull/72164


More information about the llvm-commits mailing list