Revert "[VPlan] Mark recurrence recipes as not having side-effects."
authorFlorian Hahn <flo@fhahn.com>
Tue, 6 Jun 2023 09:35:25 +0000 (11:35 +0200)
committerFlorian Hahn <flo@fhahn.com>
Tue, 6 Jun 2023 09:35:26 +0000 (11:35 +0200)
commit8f781b96e201408d1fb7b49367876a54682594ed
tree02193c560a13456df7e7f2c7ef1b91c8fe129168
parent9d30c6a721edf75d0726e07fb82cc5538fb95c16
Revert "[VPlan] Mark recurrence recipes as not having side-effects."

This reverts commit 02369b75fdd7b5fc5d9b47f1b60587c225918511.

At the moment, live-outs used *only* for the resume values in the scalar
loop are not modeled in VPlan yet. This means first-order recurrence
recipes could be removed, when a scalar epilogue is required and the
only use of a FOR is outside the loop.

Keep treating recurrence recipes as having side-effects for now, to
avoid them being removed.

Fixes #62954.
llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp
llvm/test/Transforms/LoopVectorize/X86/fixed-order-recurrence.ll
llvm/test/Transforms/LoopVectorize/first-order-recurrence.ll