Commit 96654664 by Paul Brook Committed by Paul Brook

re PR fortran/18375 (ICE when compiling spec benchmark fma3d)

	PR fortran/18375
	* trans-expr.c (gfc_trans_subarray_assign): Free shape before ss.
	* trans-io.c (transfer_array_component): Ditto.

From-SVN: r90449
parent fdc7e5d0
2004-11-10 Paul Brook <paul@codesourcery.com> 2004-11-10 Paul Brook <paul@codesourcery.com>
PR fortran/18375
* trans-expr.c (gfc_trans_subarray_assign): Free shape before ss.
* trans-io.c (transfer_array_component): Ditto.
2004-11-10 Paul Brook <paul@codesourcery.com>
* invoke.texi: Fix typo. * invoke.texi: Fix typo.
2004-11-08 Kazu Hirata <kazu@cs.umass.edu> 2004-11-08 Kazu Hirata <kazu@cs.umass.edu>
......
...@@ -1566,12 +1566,12 @@ gfc_trans_subarray_assign (tree dest, gfc_component * cm, gfc_expr * expr) ...@@ -1566,12 +1566,12 @@ gfc_trans_subarray_assign (tree dest, gfc_component * cm, gfc_expr * expr)
gfc_add_block_to_block (&block, &loop.pre); gfc_add_block_to_block (&block, &loop.pre);
gfc_add_block_to_block (&block, &loop.post); gfc_add_block_to_block (&block, &loop.post);
gfc_cleanup_loop (&loop);
for (n = 0; n < cm->as->rank; n++) for (n = 0; n < cm->as->rank; n++)
mpz_clear (lss->shape[n]); mpz_clear (lss->shape[n]);
gfc_free (lss->shape); gfc_free (lss->shape);
gfc_cleanup_loop (&loop);
return gfc_finish_block (&block); return gfc_finish_block (&block);
} }
......
...@@ -1222,12 +1222,12 @@ transfer_array_component (tree expr, gfc_component * cm) ...@@ -1222,12 +1222,12 @@ transfer_array_component (tree expr, gfc_component * cm)
gfc_add_block_to_block (&block, &loop.pre); gfc_add_block_to_block (&block, &loop.pre);
gfc_add_block_to_block (&block, &loop.post); gfc_add_block_to_block (&block, &loop.post);
gfc_cleanup_loop (&loop);
for (n = 0; n < cm->as->rank; n++) for (n = 0; n < cm->as->rank; n++)
mpz_clear (ss->shape[n]); mpz_clear (ss->shape[n]);
gfc_free (ss->shape); gfc_free (ss->shape);
gfc_cleanup_loop (&loop);
return gfc_finish_block (&block); return gfc_finish_block (&block);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment