From a0e6e49ddedb05e2e112e5c19a2228efd016e871 Mon Sep 17 00:00:00 2001 From: Richard Biener Date: Fri, 9 Oct 2020 09:47:44 +0200 Subject: random memory leak fixes This fixes leaks discovered checking whether I introduced new ones with the last vectorizer changes. 2020-10-09 Richard Biener * cgraphunit.c (expand_all_functions): Free tp_first_run_order. * ipa-modref.c (pass_ipa_modref::execute): Free order. * tree-ssa-loop-niter.c (estimate_numbers_of_iterations): Free loop body. * tree-vect-data-refs.c (vect_find_stmt_data_reference): Free data references upon failure. * tree-vect-loop.c (update_epilogue_loop_vinfo): Free BBs array of the original loop. * tree-vect-slp.c (vect_slp_bbs): Use an auto_vec for dataref_groups to release its memory. --- gcc/cgraphunit.c | 1 + 1 file changed, 1 insertion(+) (limited to 'gcc/cgraphunit.c') diff --git a/gcc/cgraphunit.c b/gcc/cgraphunit.c index bedb6e2..19ae876 100644 --- a/gcc/cgraphunit.c +++ b/gcc/cgraphunit.c @@ -2494,6 +2494,7 @@ expand_all_functions (void) delete ipa_saved_clone_sources; ipa_saved_clone_sources = NULL; free (order); + free (tp_first_run_order); } /* This is used to sort the node types by the cgraph order number. */ -- cgit v1.1