This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/18628] [4.0 regression] miscompilation of switch statement in loop
- 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: 23 Nov 2004 17:09:19 -0000
- Subject: [Bug middle-end/18628] [4.0 regression] miscompilation of switch statement in loop
- References: <20041123151338.18628.micis@gmx.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-11-23 17:09 -------
I really doubt that his change did anything except maybe change the tree level.
Here is one which can most likely reproduced before his change:
int main (int i)
{
int lsm_tmp1;
int D1127;
lsm_tmp1 = i;
L9:;
switch (lsm_tmp1)
{
case 0 ... 1: goto L10;
case 2 ... 3: goto L3;
case 5: goto L5;
default : goto L9;
}
L3:;
i = lsm_tmp1;
D1127 = 0;
goto L7;
L5:;
lsm_tmp1 = 4;
goto L9;
L10:;
i = lsm_tmp1;
D1127 = 1;
L7:;
return D1127;
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18628