[Bug middle-end/41403] miscompilation of goto/label using code
jv244 at cam dot ac dot uk
gcc-bugzilla@gcc.gnu.org
Sat Sep 19 18:48:00 GMT 2009
------- Comment #5 from jv244 at cam dot ac dot uk 2009-09-19 18:48 -------
and also fails in C
#include <stdio.h>
main()
{
int i;
int i0;
void * i1;
int icon01;
int ivfail;
int ivpass;
int D1545;
ivfail = 0;
i0 = -1;
i1 = &&label_001263;
if (i1 == &&label_001262) goto label_001262;
if (i1 == &&label_001263) goto label_001263;
if (i1 == &&label_001264) goto label_001264;
label_001262:
icon01 = 1262;
goto label_001265;
label_001263:
icon01 = 1263;
goto label_001265;
label_001264:
icon01 = 1264;
label_001265:
label_041260:
D1545 = icon01 + -1263;
if (D1545 != 0) goto label_021260; else goto label_011260;
label_011260:;
ivpass = ivpass + 1;
goto label_001271;
label_021260:
ivfail = ivfail + 1;
label_001271:
printf("%d\n",ivfail);
}
--
jv244 at cam dot ac dot uk changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P2
Summary|Optimization: NIST test |miscompilation of goto/label
|FM013.f fails at -O1 and |using code
|above |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41403
More information about the Gcc-bugs
mailing list