[PATCH] D31558: CodeGen: BranchFolding: Merge identical blocks, even if they are short.
David Li via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Apr 1 12:29:32 PDT 2017
davidxl added inline comments.
================
Comment at: lib/CodeGen/BranchFolding.cpp:604
+ // If both blocks are identical, merge them.
+ if (I1 == MBB1->begin() && I2 == MBB2->begin())
+ return true;
----------------
This may have bad effect on block layout if tail dup can recover from it. For instance, when both MBB1 and MBB2 have fall through successors.
Repository:
rL LLVM
https://reviews.llvm.org/D31558
More information about the llvm-commits
mailing list