X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=lib%2FCodeGen%2FSjLjEHPrepare.cpp;h=396fa5239da5beaa1590a9c50bda81d7fdcd001d;hb=da53f1e088ad594f604c950c6a9c62d7b6356b88;hp=d14e29b6cc08f3144fa0b61efd34d83677bce96b;hpb=9f85dccfc64b5f0b0c63ddfa0a42d8615aa1fcb3;p=oota-llvm.git diff --git a/lib/CodeGen/SjLjEHPrepare.cpp b/lib/CodeGen/SjLjEHPrepare.cpp index d14e29b6cc0..396fa5239da 100644 --- a/lib/CodeGen/SjLjEHPrepare.cpp +++ b/lib/CodeGen/SjLjEHPrepare.cpp @@ -139,7 +139,7 @@ void SjLjEHPrepare::insertCallSiteStore(Instruction *I, int Number) { /// MarkBlocksLiveIn - Insert BB and all of its predescessors into LiveBBs until /// we reach blocks we've already seen. static void MarkBlocksLiveIn(BasicBlock *BB, - SmallPtrSet &LiveBBs) { + SmallPtrSetImpl &LiveBBs) { if (!LiveBBs.insert(BB)) return; // already been here. @@ -351,10 +351,8 @@ void SjLjEHPrepare::lowerAcrossUnwindEdges(Function &F, continue; // Demote the PHIs to the stack. - for (SmallPtrSet::iterator I = PHIsToDemote.begin(), - E = PHIsToDemote.end(); - I != E; ++I) - DemotePHIToStack(*I); + for (PHINode *PN : PHIsToDemote) + DemotePHIToStack(PN); // Move the landingpad instruction back to the top of the landing pad block. LPI->moveBefore(UnwindBlock->begin());