Hi,

On Thu, Mar 12, 2020 at 10:29:45PM +0000, Segher Boessenkool wrote:
> The df dataflow solvers use the aux field in the basic_block struct,
> although that is reserved for any use by passes.  And not only that,
> it is required that you set all such fields to NULL before calling
> the solvers, or you quietly get wrong results.
> 
> This changes the solvers to use a local array for last_change_age
> instead, just like it already had a local array for last_visit_age.
> 
> Tested on powerpc64-linux {-m32,-m64}.  Also tested with the tests for
> PR94042, which it also solves (I need to confirm that still though,
> there are other testsuite problems interfering with my testing).

I can confirm it also fixes PR94042, no extra patch to shrink-wrap is
needed even (as I thought before).


Segher


>       PR rtl-optimization/94148
>       PR rtl-optimization/94042
>       * df-core.c (BB_LAST_CHANGE_AGE): Delete.
>       (df_worklist_propagate_forward): New parameter last_change_age, use
>       that instead of bb->aux.
>       (df_worklist_propagate_backward): Ditto.
>       (df_worklist_dataflow_doublequeue): Use a local array last_change_age.

Reply via email to