[Bug c/42179] Incorrect optimization (-O2) yields wrong code (regression)

vincent at vinc17 dot org gcc-bugzilla@gcc.gnu.org
Thu Nov 26 15:53:00 GMT 2009



------- Comment #4 from vincent at vinc17 dot org  2009-11-26 15:53 -------
(In reply to comment #1)
> Aliasing rules are indeed broken because you access a union of anonymous type
> through a pointer to a union of type ieee_double_extract.

OK, the real code in MPFR is a "double" accessed through a pointer to a union
of type ieee_double_extract, but I suppose this is the same problem.

BTW, could my testcase be used to improve GCC's -Wstrict-aliasing=3 (i.e. to
have fewer false negatives without introducing more false positives), or is it
too difficult / not possible?


-- 


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



More information about the Gcc-bugs mailing list