http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50327
Tobias Burnus <burnus at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|--- |4.7.0 --- Comment #1 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-09-08 13:56:17 UTC --- The problem is the replacement of "ABS(SD2)" by "tmp = ABS(SD2)" in the following DO WHILE LOOP: DO WHILE ( (ABS(SD2).LE.RGAMSQ) .OR. (ABS(SD2).GE.GAMSQ) ) IF (SFLAG.EQ.ZERO) THEN While it is OK to evaluate it only once, it needs to be evaluated every time and not once before the loop! Working: while (1) { if (!(ABS_EXPR <*sd2> <= rgamsq) && !(ABS_EXPR <*sd2> >= gamsq)) goto L.13; if (sflag == zero) Failing: real(kind=4) __var_1; __var_1 = ABS_EXPR <*sd2>; while (1) { if (!(__var_1 <= rgamsq) && !(__var_1 >= gamsq)) goto L.14; if (sflag == zero)