[llvm-commits] CVS: llvm/include/llvm/CodeGen/MachineBasicBlock.h

Evan Cheng evan.cheng at apple.com
Tue May 8 11:55:21 PDT 2007



Changes in directory llvm/include/llvm/CodeGen:

MachineBasicBlock.h updated: 1.62 -> 1.63
---
Log message:

Add MachineBasicBlock preds / succs reverse iterators.

---
Diffs of the changes:  (+24 -0)

 MachineBasicBlock.h |   24 ++++++++++++++++++++++++
 1 files changed, 24 insertions(+)


Index: llvm/include/llvm/CodeGen/MachineBasicBlock.h
diff -u llvm/include/llvm/CodeGen/MachineBasicBlock.h:1.62 llvm/include/llvm/CodeGen/MachineBasicBlock.h:1.63
--- llvm/include/llvm/CodeGen/MachineBasicBlock.h:1.62	Fri Mar 23 13:44:11 2007
+++ llvm/include/llvm/CodeGen/MachineBasicBlock.h	Tue May  8 13:55:03 2007
@@ -123,17 +123,41 @@
   typedef std::vector<MachineBasicBlock *>::const_iterator const_pred_iterator;
   typedef std::vector<MachineBasicBlock *>::iterator       succ_iterator;
   typedef std::vector<MachineBasicBlock *>::const_iterator const_succ_iterator;
+  typedef std::vector<MachineBasicBlock *>::reverse_iterator
+                                                         pred_reverse_iterator;
+  typedef std::vector<MachineBasicBlock *>::const_reverse_iterator
+                                                   const_pred_reverse_iterator;
+  typedef std::vector<MachineBasicBlock *>::reverse_iterator
+                                                         succ_reverse_iterator;
+  typedef std::vector<MachineBasicBlock *>::const_reverse_iterator
+                                                   const_succ_reverse_iterator;
 
   pred_iterator        pred_begin()       { return Predecessors.begin(); }
   const_pred_iterator  pred_begin() const { return Predecessors.begin(); }
   pred_iterator        pred_end()         { return Predecessors.end();   }
   const_pred_iterator  pred_end()   const { return Predecessors.end();   }
+  pred_reverse_iterator        pred_rbegin()
+                                          { return Predecessors.rbegin();}
+  const_pred_reverse_iterator  pred_rbegin() const
+                                          { return Predecessors.rbegin();}
+  pred_reverse_iterator        pred_rend()
+                                          { return Predecessors.rend();  }
+  const_pred_reverse_iterator  pred_rend()   const
+                                          { return Predecessors.rend();  }
   unsigned             pred_size()  const { return Predecessors.size();  }
   bool                 pred_empty() const { return Predecessors.empty(); }
   succ_iterator        succ_begin()       { return Successors.begin();   }
   const_succ_iterator  succ_begin() const { return Successors.begin();   }
   succ_iterator        succ_end()         { return Successors.end();     }
   const_succ_iterator  succ_end()   const { return Successors.end();     }
+  succ_reverse_iterator        succ_rbegin()
+                                          { return Successors.rbegin();  }
+  const_succ_reverse_iterator  succ_rbegin() const
+                                          { return Successors.rbegin();  }
+  succ_reverse_iterator        succ_rend()
+                                          { return Successors.rend();    }
+  const_succ_reverse_iterator  succ_rend()   const
+                                          { return Successors.rend();    }
   unsigned             succ_size()  const { return Successors.size();    }
   bool                 succ_empty() const { return Successors.empty();   }
 






More information about the llvm-commits mailing list