This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/21666] Optimization level -O2 breaks float (double) conversion
- 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: 19 May 2005 19:15:52 -0000
- Subject: [Bug c/21666] Optimization level -O2 breaks float (double) conversion
- References: <20050519183504.21666.jbeitaharon@intrusic.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-05-19 19:15 -------
You are violating C aliasing rules:
((long *) &s)[0] = __extension__ ({ register u_long __X = (nt.li[1]); __asm
("xchgb %h1, %b1\n\trorl $16, %1\n\txchgb %h1, %b1" : "=q" (__X) : "0" (__X));
__X; });
s is a double but you are accessing it as a long.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21666