https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100112
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |alias
Component|ipa |tree-optimization
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Hmm, the difference is in fre, for some reason -fstrict-aliasing makes a
difference.
ealias at -O1:
c.1_4 = c;
c = c.1_4;
c.2_5 = c;
_6 = c.2_5 != 0B;
ealias at -O3:
*a.0_1 = _3;
c.1_4 = c;
c = c.1_4;
c.2_5 = c;
_6 = c.2_5 != 0B;
fre1 at -O1:
*a.0_1 = _3;
c.1_4 = c;
_6 = c.1_4 != 0B;
fre1 at -O3:
*a.0_1 = _3;
c.1_4 = c;
c = c.1_4;
_6 = c.1_4 != 0B;
fre1 at -O1 dump:
Value numbering stmt = c = c.1_4;
Store matched earlier value, value numbering store vdefs to matching vuses.
fre1 at -O3 dump:
Value numbering stmt = c.1_4 = c;
Setting value number of c.1_4 to c.1_4 (changed)
Making available beyond BB2 c.1_4 for value c.1_4
Value numbering stmt = c = c.1_4;
No store match
Value numbering store c to c.1_4
Setting value number of .MEM_11 to .MEM_11 (changed)
If I use -O3 -fno-strict-aliasing, I get the same result as -O1.