diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2015-12-18 21:23:32 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2015-12-18 21:23:32 +0000 |
commit | 708a91a10366f0aa8f2b3912dd8e047ca1a66e5b (patch) | |
tree | 237dd728caae5ec779148bfa6276cd834e993feb /llvm/lib/Analysis | |
parent | 79753a07a6dc1f84099cea70aa8a8a369e909157 (diff) | |
download | bcm5719-llvm-708a91a10366f0aa8f2b3912dd8e047ca1a66e5b.tar.gz bcm5719-llvm-708a91a10366f0aa8f2b3912dd8e047ca1a66e5b.zip |
Revert "Enhance BranchProbabilityInfo::calcUnreachableHeuristics for InvokeInst"
This reverts commit r256028.
It broke:
LLVM :: CodeGen/Mips/eh.ll
LLVM :: CodeGen/Mips/insn-zero-size-bb.ll
llvm-svn: 256032
Diffstat (limited to 'llvm/lib/Analysis')
-rw-r--r-- | llvm/lib/Analysis/BranchProbabilityInfo.cpp | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/llvm/lib/Analysis/BranchProbabilityInfo.cpp b/llvm/lib/Analysis/BranchProbabilityInfo.cpp index a0d6123b583..6cdf43a06a9 100644 --- a/llvm/lib/Analysis/BranchProbabilityInfo.cpp +++ b/llvm/lib/Analysis/BranchProbabilityInfo.cpp @@ -147,16 +147,6 @@ bool BranchProbabilityInfo::calcUnreachableHeuristics(BasicBlock *BB) { if (TI->getNumSuccessors() == 1 || UnreachableEdges.empty()) return false; - // If the terminator is an InvokeInst, check only the normal destination block - // as the unwind edge of InvokeInst is also very unlikely taken. - if (auto *II = dyn_cast<InvokeInst>(TI)) - if (PostDominatedByUnreachable.count(II->getNormalDest())) { - PostDominatedByUnreachable.insert(BB); - // Return false here so that edge weights for InvokeInst could be decided - // in calcInvokeHeuristics(). - return false; - } - uint32_t UnreachableWeight = std::max(UR_TAKEN_WEIGHT / (unsigned)UnreachableEdges.size(), MIN_WEIGHT); for (SmallVectorImpl<unsigned>::iterator I = UnreachableEdges.begin(), |