Lines Matching defs:MachineBasicBlock

1 //===-- llvm/CodeGen/MachineBasicBlock.h ------------------------*- C++ -*-===//
38 // this is only set by the MachineBasicBlock owning the LiveList
39 friend class MachineBasicBlock;
40 MachineBasicBlock* Parent;
62 class MachineBasicBlock : public ilist_node<MachineBasicBlock> {
71 std::vector<MachineBasicBlock *> Predecessors;
72 std::vector<MachineBasicBlock *> Successors;
100 MachineBasicBlock() {}
102 explicit MachineBasicBlock(MachineFunction &mf, const BasicBlock *bb);
104 ~MachineBasicBlock();
138 /// bundle_iterator - MachineBasicBlock iterator that automatically skips over
244 typedef std::vector<MachineBasicBlock *>::iterator pred_iterator;
245 typedef std::vector<MachineBasicBlock *>::const_iterator const_pred_iterator;
246 typedef std::vector<MachineBasicBlock *>::iterator succ_iterator;
247 typedef std::vector<MachineBasicBlock *>::const_iterator const_succ_iterator;
248 typedef std::vector<MachineBasicBlock *>::reverse_iterator
250 typedef std::vector<MachineBasicBlock *>::const_reverse_iterator
252 typedef std::vector<MachineBasicBlock *>::reverse_iterator
254 typedef std::vector<MachineBasicBlock *>::const_reverse_iterator
331 const MachineBasicBlock *getLandingPadSuccessor() const;
338 void moveBefore(MachineBasicBlock *NewAfter);
339 void moveAfter(MachineBasicBlock *NewBefore);
349 /// addSuccessor - Add succ as a successor of this MachineBasicBlock.
356 void addSuccessor(MachineBasicBlock *succ, uint32_t weight = 0);
359 /// MachineBasicBlock. The Predecessors list of succ is automatically updated.
361 void removeSuccessor(MachineBasicBlock *succ);
364 /// this MachineBasicBlock. The Predecessors list of succ is automatically
371 void replaceSuccessor(MachineBasicBlock *Old, MachineBasicBlock *New);
377 void transferSuccessors(MachineBasicBlock *fromMBB);
382 void transferSuccessorsAndUpdatePHIs(MachineBasicBlock *fromMBB);
386 bool isPredecessor(const MachineBasicBlock *MBB) const;
390 bool isSuccessor(const MachineBasicBlock *MBB) const;
397 bool isLayoutSuccessor(const MachineBasicBlock *MBB) const;
438 MachineBasicBlock *SplitCriticalEdge(MachineBasicBlock *Succ, Pass *P);
531 void splice(iterator Where, MachineBasicBlock *Other, iterator From) {
542 void splice(iterator Where, MachineBasicBlock *Other,
550 MachineBasicBlock *removeFromParent();
558 void ReplaceUsesOfBlockWith(MachineBasicBlock *Old, MachineBasicBlock *New);
566 bool CorrectExtraCFGEdges(MachineBasicBlock *DestA,
567 MachineBasicBlock *DestB,
630 friend struct ilist_traits<MachineBasicBlock>;
634 /// addPredecessor - Remove pred as a predecessor of this MachineBasicBlock.
638 void addPredecessor(MachineBasicBlock *pred);
641 /// MachineBasicBlock. Don't do this unless you know what you're
645 void removePredecessor(MachineBasicBlock *pred);
648 raw_ostream& operator<<(raw_ostream &OS, const MachineBasicBlock &MBB);
650 void WriteAsOperand(raw_ostream &, const MachineBasicBlock*, bool t);
654 public std::unary_function<const MachineBasicBlock*, unsigned> {
655 unsigned operator()(const MachineBasicBlock *MBB) const {
668 template <> struct GraphTraits<MachineBasicBlock *> {
669 typedef MachineBasicBlock NodeType;
670 typedef MachineBasicBlock::succ_iterator ChildIteratorType;
672 static NodeType *getEntryNode(MachineBasicBlock *BB) { return BB; }
681 template <> struct GraphTraits<const MachineBasicBlock *> {
682 typedef const MachineBasicBlock NodeType;
683 typedef MachineBasicBlock::const_succ_iterator ChildIteratorType;
685 static NodeType *getEntryNode(const MachineBasicBlock *BB) { return BB; }
700 template <> struct GraphTraits<Inverse<MachineBasicBlock*> > {
701 typedef MachineBasicBlock NodeType;
702 typedef MachineBasicBlock::pred_iterator ChildIteratorType;
703 static NodeType *getEntryNode(Inverse<MachineBasicBlock *> G) {
714 template <> struct GraphTraits<Inverse<const MachineBasicBlock*> > {
715 typedef const MachineBasicBlock NodeType;
716 typedef MachineBasicBlock::const_pred_iterator ChildIteratorType;
717 static NodeType *getEntryNode(Inverse<const MachineBasicBlock*> G) {