This is an archive of the discontinued LLVM Phabricator instance.

[NFC] Factor out implicit control flow logic from GVN
ClosedPublic

Authored by mkazantsev on Nov 21 2017, 3:56 AM.

Details

Summary

Logic for tracking implicit control flow instructions was added to GVN to
perform PRE optimizations correctly. It appears that GVN is not the only
optimization that sometimes does PRE, so this logic is required in other
places (such as Jump Threading).

This is an NFC patch that encapsulates all ICF-related logic in a dedicated
utility class separated from GVN.

Diff Detail

Repository
rL LLVM

Event Timeline

mkazantsev created this revision.Nov 21 2017, 3:56 AM
mkazantsev planned changes to this revision.Dec 5 2017, 6:20 AM

Need to rebase on top of latest changes in GVN.

mkazantsev abandoned this revision.Feb 26 2018, 2:56 AM

Rebased. We need to reanimate this.

Moved fill to private API, added lazy calculations, overall it is now more user-friendly.

If nobody objects I will have it merged early next week.

mkazantsev accepted this revision.Aug 5 2018, 11:30 PM
This revision is now accepted and ready to land.Aug 5 2018, 11:30 PM
This revision was automatically updated to reflect the committed changes.