This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/17841] table lookups vs binary search in switch-statements
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Oct 2004 17:32:13 -0000
- Subject: [Bug tree-optimization/17841] table lookups vs binary search in switch-statements
- References: <20041005133432.17841.dhruvbird@yahoo.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-18 17:32 -------
We already get much better code on the mainline for this testcase as the constant for x is progated into
the case statements so we only get the storing of the value into g.
I have a fix for 4.x, there is an off by one error in the loop to combine the case and the default case.
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |pinskia at gcc dot gnu dot
|dot org |org
Severity|normal |enhancement
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17841