diff options
author | Dan Gohman <gohman@apple.com> | 2009-10-20 04:16:37 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2009-10-20 04:16:37 +0000 |
commit | 81b16a3558514481c61e7c68d19f84d7a69352cb (patch) | |
tree | 8a389b6896953c690b4842840dccf7fc7c11dccf /include/llvm/CodeGen/MachineLoopInfo.h | |
parent | 13555eae17991ab1080774947c35af9f4cc62cea (diff) |
Add getTopBlock and getBottomBlock member functions to MachineLoopInfo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84596 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen/MachineLoopInfo.h')
-rw-r--r-- | include/llvm/CodeGen/MachineLoopInfo.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/include/llvm/CodeGen/MachineLoopInfo.h b/include/llvm/CodeGen/MachineLoopInfo.h index 65ad4e4841..d3df805f64 100644 --- a/include/llvm/CodeGen/MachineLoopInfo.h +++ b/include/llvm/CodeGen/MachineLoopInfo.h @@ -38,6 +38,17 @@ namespace llvm { class MachineLoop : public LoopBase<MachineBasicBlock, MachineLoop> { public: MachineLoop(); + + /// getTopBlock - Return the "top" block in the loop, which is the first + /// block in the linear layout, ignoring any parts of the loop not + /// contiguous with the part the contains the header. + MachineBasicBlock *getTopBlock(); + + /// getBottomBlock - Return the "bottom" block in the loop, which is the last + /// block in the linear layout, ignoring any parts of the loop not + /// contiguous with the part the contains the header. + MachineBasicBlock *getBottomBlock(); + private: friend class LoopInfoBase<MachineBasicBlock, MachineLoop>; explicit MachineLoop(MachineBasicBlock *MBB) |