[Bug c++/25267] [3.4 4.0 regression] wrong code with inlining at -O2
pinskia at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Mon Dec 5 15:23:00 GMT 2005
------- Comment #2 from pinskia at gcc dot gnu dot org 2005-12-05 15:23 -------
You are violating C/C++ aliasing rules:
inline float hton(float x)
....
uint32_t* p32 = (uint32_t*)(&x);
You are accessing a float through a uint32_t.
*** This bug has been marked as a duplicate of 21920 ***
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |DUPLICATE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25267
More information about the Gcc-bugs
mailing list