Fix longstanding thinko: don't exclude

predessors of exit blocks from tail merging
consideration.

llvm-svn: 52985
This commit is contained in:
Dale Johannesen 2008-07-01 21:50:14 +00:00
parent 59b71c23de
commit ad6b3a6ed2
1 changed files with 1 additions and 2 deletions

View File

@ -697,8 +697,7 @@ bool BranchFolder::TailMergeBlocks(MachineFunction &MF) {
// transformations.)
for (MachineFunction::iterator I = MF.begin(), E = MF.end(); I != E; ++I) {
if (!I->succ_empty() && I->pred_size() >= 2 &&
I->pred_size() < TailMergeThreshold) {
if (I->pred_size() >= 2 && I->pred_size() < TailMergeThreshold) {
MachineBasicBlock *IBB = I;
MachineBasicBlock *PredBB = prior(I);
MergePotentials.clear();