https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88788

--- Comment #15 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to prathamesh3492 from comment #14)
> Created attachment 45425 [details]
> Patch
> 
> Hi,
> In the attached patch, I cache results of malloc_candidate_p_1 and avoid
> traversing "back edges".
> Does it look OK ?

I think it's overkill and not needed.

> One issue was with creation of hash_table:
> hash_table<mc_map_elem_t> *mc_cache = new hash_table<mc_map_elem_t> (100);
> 
> Using num_ssa_names instead of 100 resulted in allocation failure (and ICE)
> for spinning-smaller.ii.
> Is using a smaller number like 100 OK correctness wise ?
> 
> I think Richard's patch in comment 13 is a better approach, since returning
> false should indeed propagate quickly. Testing that patch.

Thanks, you can actually cache 'visited' around the loop over exit block preds,
just move the auto_bitmap visited; before the loop.

> Thanks,
> Prathamesh

Reply via email to