LLVM
15.0.0git
|
#include "llvm/ADT/IntervalMap.h"
Public Member Functions | |
const KeyT & | start (unsigned i) const |
const KeyT & | stop (unsigned i) const |
const ValT & | value (unsigned i) const |
KeyT & | start (unsigned i) |
KeyT & | stop (unsigned i) |
ValT & | value (unsigned i) |
unsigned | findFrom (unsigned i, unsigned Size, KeyT x) const |
findFrom - Find the first interval after i that may contain x. More... | |
unsigned | safeFind (unsigned i, KeyT x) const |
safeFind - Find an interval that is known to exist. More... | |
ValT | safeLookup (KeyT x, ValT NotFound) const |
safeLookup - Lookup mapped value for a safe key. More... | |
unsigned | insertFrom (unsigned &Pos, unsigned Size, KeyT a, KeyT b, ValT y) |
insertFrom - Add mapping of [a;b] to y if possible, coalescing as much as possible. More... | |
![]() | |
void | copy (const NodeBase< std::pair< KeyT, KeyT >, ValT, M > &Other, unsigned i, unsigned j, unsigned Count) |
copy - Copy elements from another node. More... | |
void | moveLeft (unsigned i, unsigned j, unsigned Count) |
moveLeft - Move elements to the left. More... | |
void | moveRight (unsigned i, unsigned j, unsigned Count) |
moveRight - Move elements to the right. More... | |
void | erase (unsigned i, unsigned j, unsigned Size) |
erase - Erase elements [i;j). More... | |
void | erase (unsigned i, unsigned Size) |
erase - Erase element at i. More... | |
void | shift (unsigned i, unsigned Size) |
shift - Shift elements [i;size) 1 position to the right. More... | |
void | transferToLeftSib (unsigned Size, NodeBase &Sib, unsigned SSize, unsigned Count) |
transferToLeftSib - Transfer elements to a left sibling node. More... | |
void | transferToRightSib (unsigned Size, NodeBase &Sib, unsigned SSize, unsigned Count) |
transferToRightSib - Transfer elements to a right sibling node. More... | |
int | adjustFromLeftSib (unsigned Size, NodeBase &Sib, unsigned SSize, int Add) |
adjustFromLeftSib - Adjust the number if elements in this node by moving elements to or from a left sibling node. More... | |
Additional Inherited Members | |
![]() | |
enum | |
![]() | |
std::pair< KeyT, KeyT > | first [N] |
ValT | second [N] |
Definition at line 566 of file IntervalMap.h.
|
inline |
findFrom - Find the first interval after i that may contain x.
i | Starting index for the search. |
Size | Number of elements in node. |
x | Key to search for. |
Definition at line 582 of file IntervalMap.h.
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::advanceTo(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::find(), and llvm::IntervalMap< uint64_t, uint16_t, 8, IntervalMapHalfOpenInfo< uint64_t > >::insert().
unsigned llvm::IntervalMapImpl::LeafNode< KeyT, ValT, N, Traits >::insertFrom | ( | unsigned & | Pos, |
unsigned | Size, | ||
KeyT | a, | ||
KeyT | b, | ||
ValT | y | ||
) |
insertFrom - Add mapping of [a;b] to y if possible, coalescing as much as possible.
This may cause the node to grow by 1, or it may cause the node to shrink because of coalescing.
Pos | Starting index = insertFrom(0, size, a) |
Size | Number of elements in node. |
a | Interval start. |
b | Interval stop. |
y | Value be mapped. |
Definition at line 630 of file IntervalMap.h.
Referenced by llvm::IntervalMap< uint64_t, uint16_t, 8, IntervalMapHalfOpenInfo< uint64_t > >::insert(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::iterator::insert().
|
inline |
safeFind - Find an interval that is known to exist.
This is the same as findFrom except is it assumed that x is at least within range of the last interval.
i | Starting index for the search. |
x | Key to search for. |
Definition at line 597 of file IntervalMap.h.
Referenced by llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::pathFillFind(), and llvm::IntervalMapImpl::LeafNode< uint64_t, uint16_t, N, IntervalMapHalfOpenInfo< uint64_t > >::safeLookup().
|
inline |
safeLookup - Lookup mapped value for a safe key.
It is assumed that x is within range of the last entry.
x | Key to search for. |
NotFound | Value to return if x is not in any interval. |
Definition at line 611 of file IntervalMap.h.
Referenced by llvm::IntervalMap< uint64_t, uint16_t, 8, IntervalMapHalfOpenInfo< uint64_t > >::lookup().
|
inline |
Definition at line 572 of file IntervalMap.h.
|
inline |
Definition at line 568 of file IntervalMap.h.
Referenced by llvm::IntervalMapImpl::LeafNode< uint64_t, uint16_t, N, IntervalMapHalfOpenInfo< uint64_t > >::safeLookup(), llvm::IntervalMap< uint64_t, uint16_t, 8, IntervalMapHalfOpenInfo< uint64_t > >::start(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeStart().
|
inline |
Definition at line 573 of file IntervalMap.h.
|
inline |
Definition at line 569 of file IntervalMap.h.
Referenced by llvm::IntervalMapImpl::LeafNode< uint64_t, uint16_t, N, IntervalMapHalfOpenInfo< uint64_t > >::findFrom(), llvm::IntervalMapImpl::LeafNode< uint64_t, uint16_t, N, IntervalMapHalfOpenInfo< uint64_t > >::safeFind(), llvm::IntervalMap< uint64_t, uint16_t, 8, IntervalMapHalfOpenInfo< uint64_t > >::stop(), llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::treeAdvanceTo(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeStop().
|
inline |
Definition at line 574 of file IntervalMap.h.
|
inline |
Definition at line 570 of file IntervalMap.h.
Referenced by llvm::IntervalMapImpl::LeafNode< uint64_t, uint16_t, N, IntervalMapHalfOpenInfo< uint64_t > >::safeLookup(), and llvm::IntervalMap< KeyT, ValT, N, Traits >::const_iterator::unsafeValue().