This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] Fix PR rtl-optimization/20017.

On Sat, 19 Feb 2005, Zack Weinberg wrote:
> Kazu Hirata <> writes:
> > 1. CSE folds the switch statement into an unconditional jump (but
> >    does not remove the dead jump table).  This new unconditoinal
> >    jump happens to jump to the next block.  Since CFG clean up
> >    makes no change to CFG, it does not call delete_dead_jumptables.
> To my mind CSE should recognize that it has converted a switch
> statement into an unconditional jump and therefore call
> delete_dead_jumptables itself.  Do you have any idea whether or not
> this is feasible?

I agree with Zack that the long term approach to removing these dead
jump tables should be to get rid of them at the point we modify/delete
the table jump instruction.  This should avoid ever having to call
delete_dead_jumptables, which has to scan the entire RTL stream.
Instead there are only a handful of places that perform this kind
of transformation and they only have to peek at the end of the current
basic block.

Like with ssa-form, I believe that we should slowly move the RTL
optimizers to updating some fraction of the CFG incrementally.

If thats too difficult for now, we can always apply your suggested


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]