From 6c99015fe2c1814f793530adc96f48050081612e Mon Sep 17 00:00:00 2001 From: "Duncan P. N. Exon Smith" Date: Mon, 21 Jul 2014 17:06:51 +0000 Subject: Revert "[C++11] Add predecessors(BasicBlock *) / successors(BasicBlock *) iterator ranges." This reverts commit r213474 (and r213475), which causes a miscompile on a stage2 LTO build. I'll reply on the list in a moment. llvm-svn: 213562 --- llvm/tools/llvm-diff/DifferenceEngine.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/tools/llvm-diff/DifferenceEngine.cpp') diff --git a/llvm/tools/llvm-diff/DifferenceEngine.cpp b/llvm/tools/llvm-diff/DifferenceEngine.cpp index f8e957f..7d379ef 100644 --- a/llvm/tools/llvm-diff/DifferenceEngine.cpp +++ b/llvm/tools/llvm-diff/DifferenceEngine.cpp @@ -125,8 +125,8 @@ class FunctionDifferenceEngine { unsigned getUnprocPredCount(BasicBlock *Block) const { unsigned Count = 0; - for (BasicBlock *Pred : predecessors(Block)) - if (!Blocks.count(Pred)) Count++; + for (pred_iterator I = pred_begin(Block), E = pred_end(Block); I != E; ++I) + if (!Blocks.count(*I)) Count++; return Count; } -- cgit v1.1