This is an archive of the discontinued LLVM Phabricator instance.

[EarlyIfConversion] Don't if-convert unconditional branches.
ClosedPublic

Authored by efriedma on Jan 8 2019, 5:39 PM.

Details

Summary

A block ending in an unconditional branch can have two successors if one is a landing pad. In practice, I think this only has an effect on Windows because landing pads are never empty for Itanium unwinding.

(Alternatively, I could add a check to AArch64InstrInfo::canInsertSelect, but this seems more obvious.)

Diff Detail

Repository
rL LLVM

Event Timeline

efriedma created this revision.Jan 8 2019, 5:39 PM
efriedma edited the summary of this revision. (Show Details)Jan 8 2019, 5:40 PM
mgrang accepted this revision.Jan 10 2019, 3:20 PM

LGTM. I have verified that this patch resolves the problem in our custom code base.

This revision is now accepted and ready to land.Jan 10 2019, 3:20 PM
This revision was automatically updated to reflect the committed changes.