diff options
| author | Florian Hahn <flo@fhahn.com> | 2019-07-30 17:04:58 +0000 | 
|---|---|---|
| committer | Florian Hahn <flo@fhahn.com> | 2019-07-30 17:04:58 +0000 | 
| commit | d0b6f42936bfb6d56d325c732ae79400c9c6016a (patch) | |
| tree | 9cbb1fe52e73404ff08480c1722a1c4e3e6b6fd4 /llvm/lib/Analysis | |
| parent | d9402ee03f90b2085d689b0472dc24b29bade7cf (diff) | |
| download | bcm5719-llvm-d0b6f42936bfb6d56d325c732ae79400c9c6016a.tar.gz bcm5719-llvm-d0b6f42936bfb6d56d325c732ae79400c9c6016a.zip | |
Revert [GVN] Preserve loop related analysis/canonical forms.
This reverts r367332 (git commit 2d7227ec3ac91f36fc32b1c21e72e2f1f5d030ad)
llvm-svn: 367335
Diffstat (limited to 'llvm/lib/Analysis')
| -rw-r--r-- | llvm/lib/Analysis/CFG.cpp | 11 | 
1 files changed, 2 insertions, 9 deletions
| diff --git a/llvm/lib/Analysis/CFG.cpp b/llvm/lib/Analysis/CFG.cpp index 8215b4ecbb0..18b83d6838c 100644 --- a/llvm/lib/Analysis/CFG.cpp +++ b/llvm/lib/Analysis/CFG.cpp @@ -87,18 +87,11 @@ unsigned llvm::GetSuccessorNumber(const BasicBlock *BB,  /// with multiple predecessors.  bool llvm::isCriticalEdge(const Instruction *TI, unsigned SuccNum,                            bool AllowIdenticalEdges) { -  assert(SuccNum < TI->getNumSuccessors() && "Illegal edge specification!"); -  return isCriticalEdge(TI, TI->getSuccessor(SuccNum), AllowIdenticalEdges); -} - -bool llvm::isCriticalEdge(const Instruction *TI, const BasicBlock *Dest, -                          bool AllowIdenticalEdges) {    assert(TI->isTerminator() && "Must be a terminator to have successors!"); +  assert(SuccNum < TI->getNumSuccessors() && "Illegal edge specification!");    if (TI->getNumSuccessors() == 1) return false; -  assert(find(predecessors(Dest), TI->getParent()) != pred_end(Dest) && -         "No edge between TI's block and Dest."); - +  const BasicBlock *Dest = TI->getSuccessor(SuccNum);    const_pred_iterator I = pred_begin(Dest), E = pred_end(Dest);    // If there is more than one predecessor, this is a critical edge... | 

