[llvm] r251839 - [IndVarSimplify] Rewrite loop exit values with their initial values from loop preheader
Tobias Grosser via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 2 23:19:00 PST 2015
On 11/02/2015 11:00 PM, Chen Li via llvm-commits wrote:
> Author: chenli
> Date: Mon Nov 2 16:00:15 2015
> New Revision: 251839
>
> URL: http://llvm.org/viewvc/llvm-project?rev=251839&view=rev
> Log:
> [IndVarSimplify] Rewrite loop exit values with their initial values from loop preheader
>
> Summary:
> This patch adds support to check if a loop has loop invariant conditions which lead to loop exits. If so, we know that if the exit path is taken, it is at the first loop iteration. If there is an induction variable used in that exit path whose value has not been updated, it will keep its initial value passing from loop preheader. We can therefore rewrite the exit value with
> its initial value. This will help remove phis created by LCSSA and enable other optimizations like loop unswitch.
Hi Chen Li,
this commit broke some of my bots. I reverted it in r251901. As it may
have just triggered a bug in my code, I will investigate first and send
you more information subsequently.
Best,
Tobias
More information about the llvm-commits
mailing list