[llvm] [VPlan] Model FOR resume value extraction in VPlan. (PR #93396)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 5 02:43:38 PDT 2024


================
@@ -847,14 +847,84 @@ bool VPlanTransforms::adjustFixedOrderRecurrences(VPlan &Plan,
     // all users.
     RecurSplice->setOperand(0, FOR);
 
+    // This is the second phase of vectorizing first-order recurrences. An
+    // overview of the transformation is described below. Suppose we have the
+    // following loop.
+    //
+    //   for (int i = 0; i < n; ++i)
+    //     b[i] = a[i] - a[i - 1];
+    //
----------------
fhahn wrote:

Merged with the example loop, thanks!

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


More information about the llvm-commits mailing list