From: Cong Hou Date: Thu, 10 Dec 2015 19:57:22 +0000 (+0000) Subject: Delete a duplicate branch in IfConversion.cpp. NFC. X-Git-Url: http://plrg.eecs.uci.edu/git/?p=oota-llvm.git;a=commitdiff_plain;h=dd635a682c991ecf3b61b86e8caceb842d2e8667 Delete a duplicate branch in IfConversion.cpp. NFC. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@255291 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/CodeGen/IfConversion.cpp b/lib/CodeGen/IfConversion.cpp index e90cb02bd28..71bd61a15cb 100644 --- a/lib/CodeGen/IfConversion.cpp +++ b/lib/CodeGen/IfConversion.cpp @@ -1679,15 +1679,6 @@ void IfConverter::MergeBlocks(BBInfo &ToBBI, BBInfo &FromBBI, bool AddEdges) { BranchProbability::getZero()); } - if (AddEdges && ToBBI.BB->isSuccessor(FromBBI.BB)) { - // Set the edge probability from ToBBI.BB to FromBBI.BB to zero to avoid the - // edge probability being merged to other edges when this edge is removed - // later. - ToBBI.BB->setSuccProbability( - std::find(ToBBI.BB->succ_begin(), ToBBI.BB->succ_end(), FromBBI.BB), - BranchProbability::getZero()); - } - for (unsigned i = 0, e = FromSuccs.size(); i != e; ++i) { MachineBasicBlock *Succ = FromSuccs[i]; // Fallthrough edge can't be transferred.