This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/49338] wrong code with -O2 and -O3


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49338

--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-06-09 09:08:51 UTC ---
Try -Wstrict-aliasing=2 or -Wstrict-aliasing=1 if -Wstrict-aliasing doesn't
report anything.  Anyway, why are you fighting so hard to avoid fixing your
buggy code?  It isn't hard to rewrite it using an union:
  union { U64 i; double d; } u;
  u.i = m_Value.m_U64 & ~((U64)1);
  return u.d;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]