[patch] Loop reversal (merge from killloop-branch)

Zdenek Dvorak rakdver@atrey.karlin.mff.cuni.cz
Thu Jan 26 18:01:00 GMT 2006


Hello,

> Or at least, please comment on what each thing is fixing, preferabbly in
> the source code.
> 
> 
> For example,
> 
> *************** find_data_references_in_loop (struct loo
> *** 3698,3703 ****
> --- 3744,3751 ----
>                         one_inserted = true;
>                       }
>                   }
> +               else if (TREE_CODE (opnd0) != SSA_NAME)
> +                 goto insert_dont_know_node;
>   
>                 if (TREE_CODE (opnd1) == ARRAY_REF 
>                     || TREE_CODE (opnd1) == INDIRECT_REF)
> *************** find_data_references_in_loop (struct loo
> *** 3709,3714 ****
> --- 3757,3766 ----
>                         one_inserted = true;
>                       }
>                   }
> +               else if (handled_component_p (opnd1)
> +                        || (SSA_VAR_P (opnd1)
> +                            && TREE_CODE (opnd1) != SSA_NAME))
> +                 goto insert_dont_know_node;
>   
>                 if (!one_inserted)
>                   goto insert_dont_know_node;
> 
> Why are these necessary when it should fall into the (!one_inserted)
> case?

x = a[i];

where x is a global variable.  Or any other assignment where only one
side is handled by find_data_references_in_loop.

Zdenek



More information about the Gcc-patches mailing list