=== modified file 'gcc/tree-ssa-structalias.c'
@@ -1899,6 +1899,9 @@ static htab_t pointer_equiv_class_table;
classes. */
static htab_t location_equiv_class_table;
+/* Pool of memory for storing the above */
+static alloc_pool equiv_class_pool;
+
/* Hash function for a equiv_class_label_t */
static hashval_t
@@ -1948,7 +1951,8 @@ equiv_class_add (htab_t table, unsigned
bitmap labels)
{
void **slot;
- equiv_class_label_t ecl = XNEW (struct equiv_class_label);
+ equiv_class_label_t ecl
+ = (equiv_class_label_t) pool_alloc (equiv_class_pool);
ecl->labels = labels;
ecl->equivalence_class = equivalence_class;
@@ -2159,10 +2163,14 @@ perform_var_substitution (constraint_gra
struct scc_info *si = init_scc_info (size);
bitmap_obstack_initialize (&iteration_obstack);
+ equiv_class_pool = create_alloc_pool ("equiv_class_label pool",
+ sizeof (struct equiv_class_label),
+ 64);
+ /* NULL free function, we'll free the whole pool at the end of the pass. */
pointer_equiv_class_table = htab_create (511, equiv_class_label_hash,
- equiv_class_label_eq, free);
+ equiv_class_label_eq, NULL);
location_equiv_class_table = htab_create (511, equiv_class_label_hash,
- equiv_class_label_eq, free);
+ equiv_class_label_eq, NULL);
pointer_equiv_class = 1;
location_equiv_class = 1;
@@ -2269,6 +2277,7 @@ free_var_substitution_info (struct scc_i
sbitmap_free (graph->direct_nodes);
htab_delete (pointer_equiv_class_table);
htab_delete (location_equiv_class_table);
+ free_alloc_pool (equiv_class_pool);
bitmap_obstack_release (&iteration_obstack);
}