This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/15524] [4.0 Regression] jump threading on trees is slow with switch statements with large # of cases
- From: "richard dot guenther at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Nov 2004 15:44:19 -0000
- Subject: [Bug tree-optimization/15524] [4.0 Regression] jump threading on trees is slow with switch statements with large # of cases
- References: <20040518194300.15524.pinskia@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From richard dot guenther at gmail dot com 2004-11-03 15:44 -------
Subject: Re: [4.0 Regression] jump threading on trees is slow with switch statements with large # of cases
On Wed, 3 Nov 2004 10:07:58 -0500, Andrew Pinski <pinskia@physics.uc.edu> wrote:
>
> On Nov 3, 2004, at 10:03 AM, Jeffrey A Law wrote:
>
> >
> > With loop bounds recording no longer charged to the expander it's time
> > to deal with the inefficiencies which are in the switch expander.
> >
> > Basically we have code which does
> >
> > for each case
> > for each case
> > see if the label in the outer loop matches any of the cases in the
> > inner loop (up to the current case in the outer loop).
>
> We don't really need some of this code anyways because the gimplifier
> now reorders the case statements so that you don't have to do the loop
> at all.
I believe I have seen patches from Kazu that address this.
Richard.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15524