Page MenuHomePhabricator

[IR] Revert r2694 in BasicBlock::removePredecessor

Authored by foad on May 18 2020, 8:21 AM.



r2694 fixed a bug where removePredecessor could create IR with a use not
dominated by its def in a self loop. But this could only happen in an
unreachable loop, and since that time the rules have been relaxed so
that defs don't have to dominate uses in unreachable code, so the fix is
unnecessary. The regression test added in r2691 still stands.

Diff Detail

Event Timeline

foad created this revision.May 18 2020, 8:21 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 18 2020, 8:21 AM

Huzzah! Code simplification!

This revision is now accepted and ready to land.May 18 2020, 10:05 AM
lattner accepted this revision.May 18 2020, 10:44 AM

Thank you for cleaning this up!

This revision was automatically updated to reflect the committed changes.