Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add extra Simplifier & gotoElim passes to warm/hot
If Simplifier detects trivial conditional branches where the fallthrough block is a goto block to the branch target it can remove said branches and leave behind a goto block. The resulting CFG can then potentially be cleaned up by RedundantGotoElimination. Running these two opts before BlockSplitter allows these trivial conditional branches to be completely optimized away before BlockSplitter gets a change to run and potentially duplicate blocks that hide the opportunity and make it harder to detect and eliminate later. This PR inserts Simplifer and RedundantGotoElimination passes before BlockSplitter and moves all 3 after VP, which typically detects opportunities that result in dead code, which when removed, results in the trivial conditional branches that we're interested in. Signed-off-by: Younes Manton <[email protected]>
- Loading branch information