|
LLVM
8.0.1
|
#include "llvm/ADT/IntervalMap.h"
Public Member Functions | |
| template<typename NodeT > | |
| NodeT & | node (unsigned Level) const |
| unsigned | size (unsigned Level) const |
| unsigned | offset (unsigned Level) const |
| unsigned & | offset (unsigned Level) |
| template<typename NodeT > | |
| NodeT & | leaf () const |
| unsigned | leafSize () const |
| unsigned | leafOffset () const |
| unsigned & | leafOffset () |
| bool | valid () const |
| valid - Return true if path is at a valid node, not at end(). More... | |
| unsigned | height () const |
| height - Return the height of the tree corresponding to this path. More... | |
| NodeRef & | subtree (unsigned Level) const |
| subtree - Get the subtree referenced from Level. More... | |
| void | reset (unsigned Level) |
| reset - Reset cached information about node(Level) from subtree(Level -1). More... | |
| void | push (NodeRef Node, unsigned Offset) |
| push - Add entry to path. More... | |
| void | pop () |
| pop - Remove the last path entry. More... | |
| void | setSize (unsigned Level, unsigned Size) |
| setSize - Set the size of a node both in the path and in the tree. More... | |
| void | setRoot (void *Node, unsigned Size, unsigned Offset) |
| setRoot - Clear the path and set a new root node. More... | |
| void | replaceRoot (void *Root, unsigned Size, IdxPair Offsets) |
| replaceRoot - Replace the current root node with two new entries after the tree height has increased. More... | |
| NodeRef | getLeftSibling (unsigned Level) const |
| getLeftSibling - Get the left sibling node at Level, or a null NodeRef. More... | |
| void | moveLeft (unsigned Level) |
| moveLeft - Move path to the left sibling at Level. More... | |
| void | fillLeft (unsigned Height) |
| fillLeft - Grow path to Height by taking leftmost branches. More... | |
| NodeRef | getRightSibling (unsigned Level) const |
| getLeftSibling - Get the left sibling node at Level, or a null NodeRef. More... | |
| void | moveRight (unsigned Level) |
| moveRight - Move path to the left sibling at Level. More... | |
| bool | atBegin () const |
| atBegin - Return true if path is at begin(). More... | |
| bool | atLastEntry (unsigned Level) const |
| atLastEntry - Return true if the path is at the last entry of the node at Level. More... | |
| void | legalizeForInsert (unsigned Level) |
| legalizeForInsert - Prepare the path for an insertion at Level. More... | |
Definition at line 771 of file IntervalMap.h.
|
inline |
atBegin - Return true if path is at begin().
Definition at line 898 of file IntervalMap.h.
References llvm::SmallVectorBase::size().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::atBegin(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase().
atLastEntry - Return true if the path is at the last entry of the node at Level.
| Level | Node to examine. |
Definition at line 908 of file IntervalMap.h.
References llvm::SmallVectorBase::size().
Referenced by getRightSibling(), and moveRight().
|
inline |
fillLeft - Grow path to Height by taking leftmost branches.
| Height | The target height. |
Definition at line 882 of file IntervalMap.h.
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::goToBegin().
getLeftSibling - Get the left sibling node at Level, or a null NodeRef.
| Level | Get the sibling to node(Level). |
Definition at line 25 of file IntervalMap.cpp.
References offset(), llvm::IntervalMapImpl::NodeRef::size(), and llvm::IntervalMapImpl::NodeRef::subtree().
getLeftSibling - Get the left sibling node at Level, or a null NodeRef.
| Level | Get the sinbling to node(Level). |
Definition at line 75 of file IntervalMap.cpp.
References atLastEntry(), offset(), and llvm::IntervalMapImpl::NodeRef::subtree().
|
inline |
height - Return the height of the tree corresponding to this path.
This matches map->height in a full path.
Definition at line 817 of file IntervalMap.h.
References llvm::SmallVectorBase::size().
Referenced by moveLeft().
|
inline |
Definition at line 803 of file IntervalMap.h.
References llvm::SmallVectorTemplateCommon< T, typename >::back().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeStart(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeStop(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeValue().
|
inline |
Definition at line 807 of file IntervalMap.h.
References llvm::SmallVectorTemplateCommon< T, typename >::back().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::advanceTo(), llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase(), llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::insert(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::operator++(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::operator--(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::operator==(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeStart(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeStop(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeValue().
|
inline |
Definition at line 808 of file IntervalMap.h.
References llvm::SmallVectorTemplateCommon< T, typename >::back().
|
inline |
Definition at line 806 of file IntervalMap.h.
References llvm::SmallVectorTemplateCommon< T, typename >::back().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::operator++().
|
inline |
legalizeForInsert - Prepare the path for an insertion at Level.
When the path is at end(), node(Level) may not be a legal node. legalizeForInsert ensures that node(Level) is real by moving back to the last node at Level, and setting offset(Level) to size(Level) if required.
| Level | The level where an insertion is about to take place. |
Definition at line 917 of file IntervalMap.h.
References N.
| void llvm::IntervalMapImpl::Path::moveLeft | ( | unsigned | Level | ) |
moveLeft - Move path to the left sibling at Level.
Leave nodes below Level unaltered.
| Level | Move node(Level). |
Definition at line 48 of file IntervalMap.cpp.
References assert(), height(), offset(), llvm::SmallVectorImpl< T >::resize(), llvm::IntervalMapImpl::NodeRef::size(), llvm::IntervalMapImpl::NodeRef::subtree(), subtree(), and valid().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::operator--().
| void llvm::IntervalMapImpl::Path::moveRight | ( | unsigned | Level | ) |
moveRight - Move path to the left sibling at Level.
Leave nodes below Level unaltered.
| Level | Move node(Level). |
Definition at line 98 of file IntervalMap.cpp.
References assert(), atLastEntry(), offset(), size(), llvm::IntervalMapImpl::NodeRef::subtree(), and subtree().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::operator++().
|
inline |
Definition at line 795 of file IntervalMap.h.
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase().
Definition at line 799 of file IntervalMap.h.
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase(), getLeftSibling(), getRightSibling(), moveLeft(), moveRight(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::setValue().
Definition at line 800 of file IntervalMap.h.
|
inline |
pop - Remove the last path entry.
Definition at line 840 of file IntervalMap.h.
References llvm::SmallVectorTemplateBase< T, bool >::pop_back().
push - Add entry to path.
| Node | Node to add, should be subtree(path.size()-1). |
| Offset | Offset into Node. |
Definition at line 835 of file IntervalMap.h.
replaceRoot - Replace the current root node with two new entries after the tree height has increased.
| Root | The new root node. |
| Size | Number of entries in the new root. |
| Offsets | Offsets into the root and first branch nodes. |
Definition at line 19 of file IntervalMap.cpp.
References assert(), llvm::SmallVectorTemplateCommon< T, typename >::begin(), llvm::SmallVectorBase::empty(), llvm::SmallVectorTemplateCommon< T, typename >::front(), llvm::SmallVectorImpl< T >::insert(), and subtree().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::insert().
|
inline |
reset - Reset cached information about node(Level) from subtree(Level -1).
| Level | 1..height. THe node to update after parent node changed. |
Definition at line 828 of file IntervalMap.h.
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase().
setRoot - Clear the path and set a new root node.
| Node | New root node. |
| Size | New root size. |
| Offset | Offset into root node. |
Definition at line 858 of file IntervalMap.h.
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::setRoot().
setSize - Set the size of a node both in the path and in the tree.
| Level | 0..height. Note that setting the root size won't change map->rootSize. |
| Size | New node size. |
Definition at line 848 of file IntervalMap.h.
References Size, and llvm::SmallVectorBase::size().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::insert().
Definition at line 798 of file IntervalMap.h.
References llvm::SmallVectorBase::size().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase(), and moveRight().
subtree - Get the subtree referenced from Level.
When the path is consistent, node(Level + 1) == subtree(Level).
| Level | 0..height-1. The leaves have no subtrees. |
Definition at line 822 of file IntervalMap.h.
Referenced by moveLeft(), moveRight(), and replaceRoot().
|
inline |
valid - Return true if path is at a valid node, not at end().
Definition at line 811 of file IntervalMap.h.
References llvm::SmallVectorBase::empty(), and llvm::SmallVectorTemplateCommon< T, typename >::front().
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::erase(), moveLeft(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::valid().
1.8.13