This is the mail archive of the
gcc-prs@gcc.gnu.org
mailing list for the GCC project.
Re: c/7661: gcc-3.0 optimization bug on debian GNULinux on x86 with very simple program
- From: Martin Sebor <sebor at roguewave dot com>
- To: nobody at gcc dot gnu dot org
- Cc: gcc-prs at gcc dot gnu dot org,
- Date: 20 Aug 2002 20:26:01 -0000
- Subject: Re: c/7661: gcc-3.0 optimization bug on debian GNULinux on x86 with very simple program
- Reply-to: Martin Sebor <sebor at roguewave dot com>
The following reply was made to PR c/7661; it has been noted by GNATS.
From: Martin Sebor <sebor@roguewave.com>
To: gcc-gnats@gcc.gnu.org
Cc:
Subject: Re: c/7661: gcc-3.0 optimization bug on debian GNULinux on x86 with very simple program
Date: Tue, 20 Aug 2002 14:18:55 -0600
Thomas Deselaers wrote:
...
>>Description:
>>
>
> OK, while playing around(together with Stefan Jacobs, he wanted to be
> mentioned) I found out, that this small programm:
>
> -------file:maxint.cc------------
> main() {
> int i=0;
> int oldi=0;;
> while(++i>oldi) oldi=i;
> return oldi;
> }
> ---------------------------------
>
> does work absolutely fine, when compiled without any optimization,
> but does not terminate at all, when using any optimization-options:
FYI: this looks like the same thing as PR #4371, i.e., signed integer
overflow:
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view&pr=4371&database=gcc
Regards
Martin