Home | History | Annotate | Download | only in Utils

Lines Matching refs:Blocks

70 /// \brief Build a set of blocks to extract if the input blocks are viable.
78 // Loop over the blocks, adding them to our set-vector, and aborting with an
79 // empty set if we encounter invalid blocks.
82 llvm_unreachable("Repeated basic blocks in extraction input");
97 "No blocks in this region may have entries from outside the region"
124 Blocks(buildExtractionBlockSet(BB)), NumExitBlocks(~0U) {}
129 Blocks(buildExtractionBlockSet(BBs)), NumExitBlocks(~0U) {}
133 Blocks(buildExtractionBlockSet(L.getBlocks())), NumExitBlocks(~0U) {}
138 Blocks(buildExtractionBlockSet(RN)), NumExitBlocks(~0U) {}
142 static bool definedInRegion(const SetVector<BasicBlock *> &Blocks, Value *V) {
144 if (Blocks.count(I->getParent()))
152 static bool definedInCaller(const SetVector<BasicBlock *> &Blocks, Value *V) {
155 if (!Blocks.count(I->getParent()))
162 for (SetVector<BasicBlock *>::const_iterator I = Blocks.begin(),
163 E = Blocks.end();
173 if (definedInCaller(Blocks, *OI))
177 if (!definedInRegion(Blocks, U)) {
200 if (Blocks.count(PN->getIncomingBlock(i)))
221 Blocks.remove(OldPred);
222 Blocks.insert(NewBB);
225 // Okay, update dominator sets. The blocks that dominate the new one are the
226 // blocks that dominate TIBB plus the new block itself.
237 if (Blocks.count(PN->getIncomingBlock(i))) {
255 if (Blocks.count(PN->getIncomingBlock(i))) {
266 for (SetVector<BasicBlock *>::iterator I = Blocks.begin(), E = Blocks.end();
378 if (Blocks.count(inst->getParent()))
391 // Rewrite branches to basic blocks outside of the loop to new dummy blocks
393 // blocks were originally in the code region.
399 if (!Blocks.count(TI->getParent()) &&
507 if (!Blocks.count(inst->getParent()))
519 // over all of the blocks in the extracted region, updating any terminator
520 // instructions in the to-be-extracted region that branch to blocks that are
525 for (SetVector<BasicBlock*>::const_iterator i = Blocks.begin(),
526 e = Blocks.end(); i != e; ++i) {
529 if (!Blocks.count(TI->getSuccessor(i))) {
676 Function *oldFunc = (*Blocks.begin())->getParent();
680 for (SetVector<BasicBlock*>::const_iterator i = Blocks.begin(),
681 e = Blocks.end(); i != e; ++i) {
682 // Delete the basic block from the old function, and the list of blocks
698 BasicBlock *header = *Blocks.begin();
703 // If we have any return instructions in the region, split those blocks so
724 for (SetVector<BasicBlock *>::iterator I = Blocks.begin(), E = Blocks.end();
727 if (!Blocks.count(*SI))
746 if (!Blocks.count(PN->getIncomingBlock(i)))
750 // Look at all successors of the codeReplacer block. If any of these blocks
760 if (Blocks.count(PN->getIncomingBlock(i))) {