https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123122
--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
```
if (c.1_10 != 0)
goto <bb 4>; [89.00%]
else
goto <bb 3>; [11.00%]
<bb 3> [local count: 12992276]:
_11 = c.1_10 + 1;
goto <bb 5>; [100.00%]
<bb 4> [local count: 105119324]:
f_3 = -c.1_10;
<bb 5> [local count: 118111600]:
# f_14 = PHI <f_3(4), 0(3)>
# cstore_1 = PHI <1(4), _11(3)>
```
Reduced testcase:
```
int f(int a)
{
int t = 1;
int g = 0;
if (a) g = -a; else t = a+1;
tt = t;
return g;
}
```
phiopt2 should figure out that t is 1.