except.c (free_eh_nesting_info): Free the info itself.
authorMark Mitchell <mark@codesourcery.com>
Fri, 29 Oct 1999 09:49:23 +0000 (09:49 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Fri, 29 Oct 1999 09:49:23 +0000 (09:49 +0000)
* except.c (free_eh_nesting_info): Free the info itself.
* function.c (free_after_compilation): Don't free NULL.
* gcse.c (alloc_pre_mem): Free the temp_bitmap, too.
(pre_edge_insert): Free inserted.
* stmt.c (free_stmt_status): Don't free NULL.

From-SVN: r30255

gcc/ChangeLog
gcc/except.c
gcc/function.c
gcc/gcse.c
gcc/stmt.c

index 4435b727460602891203b261475a2ae9ef359390..3680ac3bf0be8cfd66d9e557b9151a407fabdd8e 100644 (file)
@@ -1,3 +1,11 @@
+Fri Oct 29 02:51:35 1999  Mark Mitchell  <mark@codesourcery.com>
+
+       * except.c (free_eh_nesting_info): Free the info itself.
+       * function.c (free_after_compilation): Don't free NULL.
+       * gcse.c (alloc_pre_mem): Free the temp_bitmap, too.
+       (pre_edge_insert): Free inserted.
+       * stmt.c (free_stmt_status): Don't free NULL.
+
 1999-10-28 21:27 -0700  Zack Weinberg  <zack@bitmover.com>
 
        * cpplib.h (struct cpp_buffer: fname, nominal_fname,
index 3c7692c4e90e3672494a03335787ba5f0c5a9648..c6f7bf5f6f265899af8c108752860a8f71886d4d 100644 (file)
@@ -3297,5 +3297,6 @@ free_eh_nesting_info (info)
              free (info->handlers[x]);
          free (info->handlers);
        }
+      free (info);
     }
 }
index 890f62bdbae8b56ef74de6cba9042529e5e66eca..d5cdc2610cc5bfd05a73bf82a8c6a8d3b961712f 100644 (file)
@@ -426,7 +426,8 @@ free_after_compilation (f)
   if (free_machine_status)
     (*free_machine_status) (f);
 
-  free (f->x_parm_reg_stack_loc);
+  if (f->x_parm_reg_stack_loc)
+    free (f->x_parm_reg_stack_loc);
 
   f->arg_offset_rtx = NULL;
   f->return_rtx = NULL;
index 9ce3ffbd2c6227cb854ff5743cdc8ab1a3c769f0..7c0a1152fed73fb1249ea2014ab6640f08099d79 100644 (file)
@@ -4108,8 +4108,8 @@ alloc_pre_mem (n_blocks, n_exprs)
   transp = sbitmap_vector_alloc (n_blocks, n_exprs);
   comp = sbitmap_vector_alloc (n_blocks, n_exprs);
   antloc = sbitmap_vector_alloc (n_blocks, n_exprs);
-
   temp_bitmap = sbitmap_vector_alloc (n_blocks, n_exprs);
+
   pre_optimal = NULL;
   pre_redundant = NULL;
   pre_insert_map = NULL;
@@ -4130,6 +4130,7 @@ free_pre_mem ()
   free (transp);
   free (comp);
   free (antloc);
+  free (temp_bitmap);
 
   if (pre_optimal)
     free (pre_optimal);
@@ -4535,6 +4536,10 @@ pre_edge_insert (edge_list, index_map)
            }
        }
     }
+
+  /* Clean up.  */
+  free (inserted);
+
   return did_insert;
 }
 
index eeab664f6ce0b2edd19ebab131a514a355a02397..f47e9fa45079a66f720aa899c9c517c5752f463b 100644 (file)
@@ -559,8 +559,8 @@ free_stmt_status (f)
   /* We're about to free the function obstack.  If we hold pointers to
      things allocated there, then we'll try to mark them when we do
      GC.  So, we clear them out here explicitly.  */
-
-  free (f->stmt);
+  if (f->stmt)
+    free (f->stmt);
   f->stmt = NULL;
 }