Lines Matching refs:Node
53 PointerIntPair<NodeType*, 2, ItMode> Node;
58 // advanceRegionSucc - A region node has only one successor. It reaches end
61 assert(Node.getInt() == ItRgBegin && "Cannot advance region successor!");
62 Node.setInt(ItRgEnd);
65 NodeType* getNode() const{ return Node.getPointer(); }
68 bool isRegionMode() const { return Node.getInt() != ItBB; }
81 assert(Node.getInt() == ItRgBegin && "Cannot get the region successor!");
95 inline RNSuccIterator(NodeType* node)
96 : Node(node, node->isSubRegion() ? ItRgBegin : ItBB),
97 BItor(BlockTraits::child_begin(node->getEntry())) {
101 while (BlockTraits::child_end(node->getEntry()) != BItor && isExit(*BItor))
109 inline RNSuccIterator(NodeType* node, bool)
110 : Node(node, node->isSubRegion() ? ItRgEnd : ItBB),
111 BItor(BlockTraits::child_end(node->getEntry())) {}
116 return Node.getInt() == x.Node.getInt();
164 NodeType* Node;
173 /// Note that the incoming node must be a bb node, otherwise it will trigger
175 inline RNSuccIterator(NodeType* node) :
176 Node(node),
177 Itor(BlockTraits::child_begin(node->getEntry())) {
178 assert(!Node->isSubRegion()
179 && "Subregion node not allowed in flat iterating mode!");
180 assert(Node->getParent() && "A BB node must have a parent!");
183 while (BlockTraits::child_end(Node->getEntry()) != Itor
184 && Node->getParent()->getExit() == *Itor)
189 inline RNSuccIterator(NodeType* node, bool) :
190 Node(node),
191 Itor(BlockTraits::child_end(node->getEntry())) {
192 assert(!Node->isSubRegion()
193 && "Subregion node not allowed in flat iterating mode!");
197 assert(Node->getParent() == x.Node->getParent()
200 return Itor == x.Itor && Node == x.Node;
209 RegionT *Parent = Node->getParent();
222 while (Itor != succ_end(Node->getEntry())
223 && Node->getParent()->getExit() == *Itor);
236 inline RNSuccIterator<NodeType, BlockT, RegionT> succ_begin(NodeType* Node) {
237 return RNSuccIterator<NodeType, BlockT, RegionT>(Node);
241 inline RNSuccIterator<NodeType, BlockT, RegionT> succ_end(NodeType* Node) {
242 return RNSuccIterator<NodeType, BlockT, RegionT>(Node, true);
249 // NodeT can either be region node or const region node, otherwise child_begin