optimization/9808: optimisation bug in (float*) to (int*) conversion

ebotcazou@gcc.gnu.org ebotcazou@gcc.gnu.org
Sat Feb 22 20:21:00 GMT 2003


Synopsis: optimisation bug in (float*) to (int*) conversion

State-Changed-From-To: open->closed
State-Changed-By: ebotcazou
State-Changed-When: Sat Feb 22 20:21:54 2003
State-Changed-Why:
    Not a bug. The original code breaks the ISO C++ aliasing
    rules (a 'long' is aliasing a 'double'). GCC automatically
    turns on -fstrict-aliasing at -O2 so you must either fix the
    code or compile with -fno-strict-aliasing.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=9808



More information about the Gcc-bugs mailing list