LLVM API Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Friends | List of all members
llvm::MachineLoop Class Reference

#include <MachineLoopInfo.h>

Inheritance diagram for llvm::MachineLoop:
Inheritance graph
[legend]
Collaboration diagram for llvm::MachineLoop:
Collaboration graph
[legend]

Public Member Functions

 MachineLoop ()
 
MachineBasicBlockgetTopBlock ()
 
MachineBasicBlockgetBottomBlock ()
 
void dump () const
 
- Public Member Functions inherited from llvm::LoopBase< MachineBasicBlock, MachineLoop >
 LoopBase ()
 Loop ctor - This creates an empty loop. More...
 
 ~LoopBase ()
 
unsigned getLoopDepth () const
 
BlockT * getHeader () const
 
LoopT * getParentLoop () const
 
void setParentLoop (LoopT *L)
 setParentLoop is a raw interface for bypassing addChildLoop. More...
 
bool contains (const LoopT *L) const
 
bool contains (const BlockT *BB) const
 
bool contains (const InstT *Inst) const
 
const std::vector< LoopT * > & getSubLoops () const
 
std::vector< LoopT * > & getSubLoopsVector ()
 
iterator begin () const
 
iterator end () const
 
reverse_iterator rbegin () const
 
reverse_iterator rend () const
 
bool empty () const
 
const std::vector< BlockT * > & getBlocks () const
 
block_iterator block_begin () const
 
block_iterator block_end () const
 
unsigned getNumBlocks () const
 getNumBlocks - Get the number of blocks in this loop in constant time. More...
 
bool isLoopExiting (const BlockT *BB) const
 
unsigned getNumBackEdges () const
 
void getExitingBlocks (SmallVectorImpl< BlockT * > &ExitingBlocks) const
 
BlockT * getExitingBlock () const
 
void getExitBlocks (SmallVectorImpl< BlockT * > &ExitBlocks) const
 
BlockT * getExitBlock () const
 
void getExitEdges (SmallVectorImpl< Edge > &ExitEdges) const
 getExitEdges - Return all pairs of (inside_block,outside_block). More...
 
BlockT * getLoopPreheader () const
 
BlockT * getLoopPredecessor () const
 
BlockT * getLoopLatch () const
 
void addBasicBlockToLoop (BlockT *NewBB, LoopInfoBase< BlockT, LoopT > &LI)
 
void replaceChildLoopWith (LoopT *OldChild, LoopT *NewChild)
 
void addChildLoop (LoopT *NewChild)
 
LoopT * removeChildLoop (iterator I)
 
void addBlockEntry (BlockT *BB)
 
void reverseBlock (unsigned from)
 reverseBlocks - interface to reverse Blocks[from, end of loop] in this loop More...
 
void reserveBlocks (unsigned size)
 reserveBlocks- interface to do reserve() for Blocks More...
 
void moveToHeader (BlockT *BB)
 
void removeBlockFromLoop (BlockT *BB)
 
void verifyLoop () const
 verifyLoop - Verify loop structure More...
 
void verifyLoopNest (DenseSet< const LoopT * > *Loops) const
 verifyLoop - Verify loop structure of this loop and all nested loops. More...
 
void print (raw_ostream &OS, unsigned Depth=0) const
 

Friends

class LoopInfoBase< MachineBasicBlock, MachineLoop >
 

Additional Inherited Members

- Public Types inherited from llvm::LoopBase< MachineBasicBlock, MachineLoop >
typedef std::vector< LoopT * >
::const_iterator 
iterator
 
typedef std::vector< LoopT * >
::const_reverse_iterator 
reverse_iterator
 
typedef std::vector< BlockT * >
::const_iterator 
block_iterator
 
typedef std::pair< const
BlockT *, const BlockT * > 
Edge
 Edge type. More...
 
- Protected Member Functions inherited from llvm::LoopBase< MachineBasicBlock, MachineLoop >
 LoopBase (BlockT *BB)
 

Detailed Description

Definition at line 44 of file MachineLoopInfo.h.

Constructor & Destructor Documentation

llvm::MachineLoop::MachineLoop ( )

Member Function Documentation

void MachineLoop::dump ( ) const
MachineBasicBlock * MachineLoop::getBottomBlock ( )

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.

Definition at line 63 of file MachineLoopInfo.cpp.

References llvm::LoopBase< MachineBasicBlock, MachineLoop >::contains(), llvm::MachineFunction::end(), llvm::LoopBase< MachineBasicBlock, MachineLoop >::getHeader(), llvm::MachineBasicBlock::getParent(), llvm::next(), and llvm::prior().

MachineBasicBlock * MachineLoop::getTopBlock ( )

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.

Definition at line 49 of file MachineLoopInfo.cpp.

References llvm::MachineFunction::begin(), llvm::LoopBase< MachineBasicBlock, MachineLoop >::contains(), llvm::LoopBase< MachineBasicBlock, MachineLoop >::getHeader(), llvm::MachineBasicBlock::getParent(), and llvm::prior().

Friends And Related Function Documentation

friend class LoopInfoBase< MachineBasicBlock, MachineLoop >
friend

Definition at line 61 of file MachineLoopInfo.h.


The documentation for this class was generated from the following files: