This is the mail archive of the
mailing list for the GCC project.
Re: PR 11350
> On Sat, Jan 10, 2004 at 10:48:07PM +0100, Jan Hubicka wrote:
> > * cfgcleanup.c (try_optimize_cfg): Supress tablejump removal
> > after reload.
> Havn't we tried this before, and gotten the exact opposite problem?
> That is, tablejumps referencing labels that are no longer present.
You changed in in patch:
you may see my followup that I worried about it that time too. You
didn't included any testcase, but I think this scheme is safe - if we
don't elliminate tablejump before reload, we just keep it around even if
all entires in table are equivalent.
It is shame that we won't clean up these jumptables, but perhaps
crossjumping before reload would take care of most of these.
I am not sure how much it matters in real code and I don't see any other
One alternate scheme is to allow changing tablejumps into directjumps
(ie keep flow2_completted check in try_redirect_by_replacing_jump) and
rely on flow2 to elliminate dead jumptables if they are dead and keep it
around if they are still referenced for no good reason and try to
preserve it in the code. But that scheme had problems too (losing the
branch destinations as the edges were missing).