Hello,

On 22/08/2012 07:56, Tobias Burnus wrote:
> Committed as Rev. 190586 after successful regtesting.
> 
> That's the version I also had attached to
> http://gcc.gnu.org/ml/fortran/2012-08/msg00118.html; as written there:
I have one minor comment about it. See below.
> 
> "The patch is incomplete, e.g. "argss" of gfc_conv_procedure_call is not
> (or not always) freed. Ditto for rss of gfc_trans_assignment_1; 
>From glancing at the code, I don't see why rss is not freed by
gfc_cleanup_loop for the latter.


> Index: gcc/fortran/trans-expr.c
> ===================================================================
> --- gcc/fortran/trans-expr.c  (Revision 190585)
> +++ gcc/fortran/trans-expr.c  (Arbeitskopie)
> @@ -6770,6 +6771,7 @@ gfc_trans_arrayfunc_assign (gfc_expr * expr1, gfc_
>        if (!expr2->value.function.isym)
>       {
>         realloc_lhs_loop_for_fcn_call (&se, &expr1->where, &ss, &loop);
> +       gfc_cleanup_loop (&loop);
>         ss->is_alloc_lhs = 1;
>       }
>        else
This takes care of freeing ss along the way, but ss should be freed
outside of the conditional too.

Mikael

Reply via email to