OSDN Git Service

* stmt.c (unroll_block_trees): Free block_vector if needed.
authorlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 23 Mar 1998 22:49:48 +0000 (22:49 +0000)
committerlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 23 Mar 1998 22:49:48 +0000 (22:49 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@18786 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/stmt.c

index 96fb0ca..3aaf8a1 100644 (file)
@@ -1,3 +1,7 @@
+Mon Mar 23 23:49:47 1998  Jeffrey A Law  (law@cygnus.com)
+
+       * stmt.c (unroll_block_trees): Free block_vector if needed.
+
 Mon Mar 23 23:26:42 1998  Philippe De Muyter  <phdm@macqel.be>
 
        * m68k/m68k.md (zero_extendqidi2, zero_extendhidi2): New patterns.
index 207a4ad..2b518fc 100644 (file)
@@ -5684,7 +5684,10 @@ emit_case_nodes (index, node, default_label, index_type)
 /* These routines are used by the loop unrolling code.  They copy BLOCK trees
    so that the debugging info will be correct for the unrolled loop.  */
 
-/* Indexed by block number, contains a pointer to the N'th block node.  */
+/* Indexed by block number, contains a pointer to the N'th block node.
+
+  Allocated by the call to identify_blocks, then released after the call
+  to reorder_blocks in the function unroll_block_trees.  */
 
 static tree *block_vector;
 
@@ -5702,4 +5705,8 @@ unroll_block_trees ()
   tree block = DECL_INITIAL (current_function_decl);
 
   reorder_blocks (block_vector, block, get_insns ());
+
+  /* Release any memory allocated by identify_blocks.  */
+  if (block_vector)
+    free (block_vector);
 }