]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
ggc_free basic blocks
authorJan Hubicka <jh@suse.cz>
Sat, 2 Jan 2021 15:05:17 +0000 (16:05 +0100)
committerJan Hubicka <jh@suse.cz>
Sat, 2 Jan 2021 15:05:17 +0000 (16:05 +0100)
* cfg.c (free_block): ggc_free bb.

gcc/cfg.c

index 529b6ed2105acc77ce572dcb60e1abf4f80a0177..e8bd1456c9f313ee12cb98aa32b547fcd4643b7b 100644 (file)
--- a/gcc/cfg.c
+++ b/gcc/cfg.c
@@ -102,8 +102,7 @@ free_block (basic_block bb)
    bb->succs = NULL;
    vec_free (bb->preds);
    bb->preds = NULL;
-   /* Do not free BB itself yet since we leak pointers to dead statements
-      that points to dead basic blocks.  */
+   ggc_free (bb);
 }
 
 /* Free the memory associated with the CFG in FN.  */