https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116090

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
The problem here is:
9 -> 10: one_pred = _21 != 0
        ((NOT (_10 != _15)) AND (_21 != 0))
After normalization [USE]:
        UseValue (opt_20);
  is conditional on:
        ((_24 != 0) AND (n_12 != 0) AND (NOT (_10 != _15)))


But _24 is defined as:
  _24 = (bool) opt$4_17;

uninit does not go and see that opt$4_17 is only [0,1] and the expression
should be transformed into:
((opt$4_17 != 0) AND (n_12 != 0) AND (NOT (_10 != _15)))

And notice:
  # opt$4_17 = PHI <opt$4_36(4), 0(6), 0(15)>

Which then will work with the def just fine:
After normalization [DEF]:
        opt_20 = PHI <_2(4), opt_33(6), opt_7(D)(15)>
  is conditional on:
        ((_14 != 0))
        OR ((NOT (opt$4_36 != 0)))

Reply via email to