This is the mail archive of the
mailing list for the GCC project.
Re: [patch] Remove strange case cost code
Il 17/04/2012 10:45, Richard Guenther ha scritto:
> > Also it is possble to get an historgrams from profile feedback into
> > switch expansion. I always wanted to do that once switch expansion code
> > is cleaned up and moved to gimple level...
> Indeed. At least the parts that expand switch stmts to (balanced) trees
> should be moved to the GIMPLE level, retaining only the table-jump-like
> expansions as switch stmts.
This would also make it much easier to drop the range checking from
switch statements (VRP would just fold those away). Also, targets could
choose between casesi and tablejump. ARM can benefit from that.