This is an archive of the discontinued LLVM Phabricator instance.

[SimplifyCFG] Move a portion of an if statement that should already be implied to an assert
ClosedPublic

Authored by craig.topper on Jul 5 2017, 11:21 AM.

Details

Summary

In this code we got to Dom by following the predecessor link of BB. So it stands to reason that BB should also show up as a successor of Dom's terminator right? There isn't a way to have the CFG connect in only one direction is there?

Diff Detail

Repository
rL LLVM

Event Timeline

craig.topper created this revision.Jul 5 2017, 11:21 AM
mcrosier accepted this revision.Jul 6 2017, 9:18 AM
mcrosier added a subscriber: mcrosier.

LGTM. My guess is that this was a very old check due to ill-formed IR, but the code has changed over the years and in it's current state your assumption seems correct.

This revision is now accepted and ready to land.Jul 6 2017, 9:18 AM
This revision was automatically updated to reflect the committed changes.