Stxxl
1.4.0
|
Loser tree from Knuth, "Sorting and Searching", Section 5.4.1 ! More...
#include <pq_losertree.h>
Loser tree from Knuth, "Sorting and Searching", Section 5.4.1 !
!
KNKMAX | maximum arity of loser tree, has to be a power of two |
Definition at line 36 of file pq_losertree.h.
typedef Cmp_ stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::comparator_type |
Definition at line 40 of file pq_losertree.h.
typedef value_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::Element |
Definition at line 41 of file pq_losertree.h.
typedef ValTp_ stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::value_type |
Definition at line 39 of file pq_losertree.h.
stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::loser_tree | ( | ) |
Definition at line 206 of file pq_losertree.h.
References stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::current, stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::current_end, stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::free_slots, stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::init(), stxxl::priority_queue_local::internal_bounded_stack< Tp_, max_size_ >::push(), stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::segment, and stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::sentinel.
stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::~loser_tree | ( | ) |
Definition at line 461 of file pq_losertree.h.
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::compactTree | ( | ) | [private] |
Definition at line 357 of file pq_losertree.h.
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::deallocate_segment | ( | unsigned_type | slot | ) | [private] |
Definition at line 479 of file pq_losertree.h.
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::doubleK | ( | ) | [private] |
Definition at line 326 of file pq_losertree.h.
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::init | ( | ) |
Definition at line 218 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::loser_tree(), and main().
unsigned_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::initWinner | ( | unsigned_type | root | ) | [private] |
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::insert_segment | ( | Element * | target, |
unsigned_type | length | ||
) |
Definition at line 414 of file pq_losertree.h.
Referenced by main().
bool stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::is_segment_empty | ( | unsigned_type | slot | ) | [inline, private] |
Definition at line 681 of file pq_losertree.h.
bool stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::is_sentinel | ( | const Element & | a | ) | [inline] |
Definition at line 155 of file pq_losertree.h.
bool stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::is_space_available | ( | ) | const [inline] |
Definition at line 195 of file pq_losertree.h.
unsigned_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::mem_cons | ( | ) | const [inline] |
Definition at line 193 of file pq_losertree.h.
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::multi_merge | ( | Element * | begin, |
Element * | end | ||
) | [inline] |
Definition at line 187 of file pq_losertree.h.
Referenced by main().
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::multi_merge | ( | Element * | target, |
unsigned_type | length | ||
) |
Definition at line 504 of file pq_losertree.h.
References stxxl::priority_queue_local::merge3_iterator(), stxxl::priority_queue_local::merge4_iterator(), and stxxl::priority_queue_local::merge_iterator().
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::multi_merge_k | ( | Element * | target, |
unsigned_type | length | ||
) | [private] |
bool stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::not_sentinel | ( | const Element & | a | ) | [inline] |
Definition at line 159 of file pq_losertree.h.
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::rebuildLoserTree | ( | ) | [private] |
Definition at line 231 of file pq_losertree.h.
unsigned_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::size | ( | ) | const [inline] |
Definition at line 201 of file pq_losertree.h.
Referenced by main().
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::swap | ( | loser_tree< ValTp_, Cmp_, KNKMAX > & | obj | ) | [inline] |
Definition at line 169 of file pq_losertree.h.
Referenced by std::swap().
void stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::update_on_insert | ( | unsigned_type | node, |
const Element & | newKey, | ||
unsigned_type | newIndex, | ||
Element * | winnerKey, | ||
unsigned_type * | winnerIndex, | ||
unsigned_type * | mask | ||
) | [private] |
comparator_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::cmp [private] |
Definition at line 52 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
Element* stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::current[KNKMAX] [private] |
Definition at line 71 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::loser_tree(), and stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
Element* stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::current_end[KNKMAX] [private] |
Definition at line 72 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::loser_tree(), and stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
internal_bounded_stack<unsigned_type, KNKMAX> stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::free_slots [private] |
Definition at line 54 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::loser_tree(), and stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
unsigned_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::k [private] |
Definition at line 58 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
unsigned_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::logK [private] |
Definition at line 57 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
unsigned_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::mem_cons_ [private] |
Definition at line 76 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
Element* stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::segment[KNKMAX] [private] |
Definition at line 73 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::loser_tree(), and stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
unsigned_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::segment_size[KNKMAX] [private] |
Definition at line 74 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
Element stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::sentinel [private] |
Definition at line 60 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::loser_tree(), and stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().
unsigned_type stxxl::priority_queue_local::loser_tree< ValTp_, Cmp_, KNKMAX >::size_ [private] |
Definition at line 56 of file pq_losertree.h.
Referenced by stxxl::priority_queue_local::loser_tree< value_type, comparator_type, IntKMAX >::swap().