[PATCH] Handle ADDR_EXPR in SCEV

Richard Guenther richard.guenther@gmail.com
Wed Feb 17 11:11:00 GMT 2010


On Wed, Feb 17, 2010 at 11:57 AM, Alexander Monakov <amonakov@ispras.ru> wrote:
>
>
> On Wed, 17 Feb 2010, Richard Guenther wrote:
>
>> The patch seems to be garbled after the first hunk.
>
> The patch consists of only one hunk but indeed somehow much garbage sneaked
> in.  Resending.

+             base = build_fold_addr_expr (base);
+             chrec1 = analyze_scalar_evolution (loop, base);

you should avoid build_fold_addr_expr here and explicitly handle
{MISALIGNED,}INDIRECT_REF of an SSA_NAME and DECLs, where you
don't need analyze_scalar_evolution but set chrec1 to &base.
For non-DECL and non-INDIRECT_REF you should give up.

Otherwise the patch looks good (the above is just to make
the analysis not allocate memory unnecessarily).  I'll test
its effect on SPEC2006.

Thanks,
Richard.



More information about the Gcc-patches mailing list