https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110891
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|unassigned at gcc dot gnu.org |pinskia at gcc dot gnu.org --- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> --- I have a patch for what I laid out in comment #3 and it solves the original issue too because after ifcombine we have: _24 = _28 == &c; _18 = _28 == &d; _8 = _18 | _24; _25 = _28 == &a; _20 = _8 | _25; if (_20 != 0) goto <bb 4>; [99.98%] else goto <bb 3>; [0.02%] <bb 3> [local count: 210453]: __assert_fail ("", "", 4, &__PRETTY_FUNCTION__); <bb 4> [local count: 536765685]: _6 = _28 == &c; _13 = _28 == &d; _9 = _6 | _13; _27 = _28 == &a; _17 = _9 | _27; if (_17 != 0) goto <bb 6>; [99.98%] else goto <bb 5>; [0.02%] Which then obviously gets optimized by DOM2.