summaryrefslogtreecommitdiff
path: root/gcc/tree-loop-linear.c
diff options
context:
space:
mode:
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2006-10-06 16:57:27 +0000
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2006-10-06 16:57:27 +0000
commit627611830da31e38930469b6e5d577043abc9022 (patch)
treeac2555c908e09e415f6469a5dbdd8f4a4c0500b8 /gcc/tree-loop-linear.c
parent3e69d97d6fb5eee0924045e340d33ef407cc0455 (diff)
downloadgcc-627611830da31e38930469b6e5d577043abc9022.tar.gz
PR tree-optimization/29330
* tree-data-ref.c (free_data_ref): Use DR_FREE_ACCESS_FNS macro. (initialize_data_dependence_relation): Clear DDR_LOOP_NEST pointer on newly allocated ddrs. (find_loop_nest_1, find_loop_nest): Change LOOP_NEST to a pointer to VEC (loop_p, heap) pointer. (compute_data_dependences_for_loop): Adjust caller. (free_dependence_relations): Free DDR_LOOP_NEST. * tree-loop-linear.c (linear_transform_loops): Don't forget to free DEPENDENCE_RELATIONS and DATAREFS. * gcc.dg/pr29330.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@117509 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-loop-linear.c')
-rw-r--r--gcc/tree-loop-linear.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/gcc/tree-loop-linear.c b/gcc/tree-loop-linear.c
index 2ef7eacec13..2840e9be4b7 100644
--- a/gcc/tree-loop-linear.c
+++ b/gcc/tree-loop-linear.c
@@ -308,7 +308,7 @@ linear_transform_loops (struct loops *loops)
{
if (dump_file)
fprintf (dump_file, "Won't transform loop. Optimal transform is the identity transform\n");
- continue;
+ goto free_and_continue;
}
/* Check whether the transformation is legal. */
@@ -316,15 +316,15 @@ linear_transform_loops (struct loops *loops)
{
if (dump_file)
fprintf (dump_file, "Can't transform loop, transform is illegal:\n");
- continue;
+ goto free_and_continue;
}
before = gcc_loopnest_to_lambda_loopnest (loops, loop_nest, &oldivs,
&invariants);
if (!before)
- continue;
-
+ goto free_and_continue;
+
if (dump_file)
{
fprintf (dump_file, "Before:\n");
@@ -346,6 +346,7 @@ linear_transform_loops (struct loops *loops)
if (dump_file)
fprintf (dump_file, "Successfully transformed loop.\n");
+ free_and_continue:
free_dependence_relations (dependence_relations);
free_data_refs (datarefs);
}