Bug Report: loop optimizer causes invalid value in gcc version 20000108

Jose Luu jluu@mainsoft.com
Thu Jan 20 10:41:00 GMT 2000


Please note that I fixed it:
http://gcc.gnu.org/ml/gcc-patches/2000-01/msg00783.html


-----Message d'origine-----
De : Jose Luu <jluu@mainsoft.com>
À : gcc-bugs@gcc.gnu.org <gcc-bugs@gcc.gnu.org>
Date : Thursday, January 20, 2000 12:38 PM
Objet : Bug Report: loop optimizer causes invalid value in gcc version
20000108


>
>The following test fails with -O2    (or with -fstrength-reduce)
>
>I will be attempting to fix, any information or help is welcomed.
>
>Regards
>Jose Luu
>-----------------------------------------------------------
>#include <stdio.h>
>
>int main ()
>{
>    int nResult;
>    int b=0;
>    int i = -1;
>    printf ("i = %d, b = %d\n", i, b);
>
>    do
>    {
> printf ("i = %d, b = %d\n", i, b);
>     if (b!=0) {
>  printf ("test FAIL \n");
>  nResult=1;
>     } else {
>  printf ("test PASS \n");
>  nResult=0;
>  }
> i++;
>        b=(i+2)*4;
>    } while (i < 0);
>    return nResult;
>}
>
>



More information about the Gcc-bugs mailing list