This is the mail archive of the
gcc-prs@gcc.gnu.org
mailing list for the GCC project.
Re: optimization/9794: Problem with -O2 on solaris causing variables to be overwritten
- From: ebotcazou at gcc dot gnu dot org
- To: gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org, wlp at ll dot mit dot edu
- Date: 22 Feb 2003 10:24:47 -0000
- Subject: Re: optimization/9794: Problem with -O2 on solaris causing variables to be overwritten
- Reply-to: ebotcazou at gcc dot gnu dot org, gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org, wlp at ll dot mit dot edu, gcc-gnats at gcc dot gnu dot org
Synopsis: Problem with -O2 on solaris causing variables to be overwritten
State-Changed-From-To: open->closed
State-Changed-By: ebotcazou
State-Changed-When: Sat Feb 22 10:24:47 2003
State-Changed-Why:
Not a bug. Your code breaks the ISO C++ aliasing rules.
GCC automatically turns on -fstrict-aliasing (see the docs,
Optimize options section) at -O2, so you must either fix
your code or compile it with -fno-strict-aliasing.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=9794