[llvm] [VPlan] Introduce dedicated canonical IV inc recipe (PR #185739)

Ramkumar Ramachandra via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 10 13:52:48 PDT 2026


================
@@ -3926,6 +3926,57 @@ class VPCurrentIterationPHIRecipe : public VPHeaderPHIRecipe {
 #endif
 };
 
+/// A recipe to compute increments to a canonical induction, supplied as \p
+/// Start, that has non-uniform unrolling. Unrolling adds an extra offset
+/// operand for unrolled parts > 0 and it produces `add Start, Offset`. The
+/// offset for unrolled part 0 is 0.
+class VPCanonicalIVIncrementRecipe : public VPSingleDefRecipe {
----------------
artagnon wrote:

Hm, I think you're right. I can make all the improvements I wanted, and re-use the VPInstruction with the opcode, without creating a fresh recipe class. Will update soon.

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


More information about the llvm-commits mailing list