This is an archive of the discontinued LLVM Phabricator instance.

[Local] Refactor llvm::removeUnreachableBlocks
AbandonedPublic

Authored by bjope on Apr 25 2018, 5:22 AM.

Details

Reviewers
None
Summary

Refactored llvm::removeUnreachableBlocks, including the
markAliveBlocks helper. The part in markAliveBlocks that
examines instructions inside a basic block, and that can
change instructions to unreachable, was factored out to
a new rewriteUnreachableInstrs helper.

Also added a new boolean parameter to removeUnreachableBlocks
to be able to skip the rewriteUnreachableInstrs part.

Diff Detail

Event Timeline

bjope created this revision.Apr 25 2018, 5:22 AM
bjope abandoned this revision.Aug 16 2018, 9:20 AM

I was going to use this in another patch, but it's outdated now so I'll abandon this.