[PATCH] Little improvement in IndVarSimplify

Michele Scandale michele.scandale at gmail.com
Wed Jun 26 12:59:33 PDT 2013


On 06/24/2013 06:12 PM, Michele Scandale wrote:
> Hi everybody,
>
> I would like to propose a little improvement to IndVarSimplify pass. The
> attached patch adds a special handling of the case where, during the loop exit
> condition rewriting, the exit value is a constant of bitwidth lower than the
> type of the induction variable: instead of introducing a trunc operation in
> order to match correctly the operand types, it allows to convert the constant
> value to an equivalent constant, depending on the initial value of the induction
> variable and the trip count, in order have an equivalent comparison between the
> induction variable and the new constant.
>
> Thanks in advance.
>
> Michele Scandale
>

Up.

Thanks again.

Michele Scandale



More information about the llvm-commits mailing list