This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/36149] -O2 optimization generates wrong code
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 6 May 2008 15:45:26 -0000
- Subject: [Bug c++/36149] -O2 optimization generates wrong code
- References: <bug-36149-16153@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #6 from pinskia at gcc dot gnu dot org 2008-05-06 15:45 -------
As I mentioned it looks like you are violating aliasing rules. Basically you
are accessing one type as another. But without a full testcase I cann't be
sure. Also Does -O2 -fno-strict-aliasing work?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36149