.TH "__gnu_parallel::_LoserTreeBase< _Tp, _Compare >" 3cxx "Wed Jul 28 2021" "libstdc++" \" -*- nroff -*- .ad l .nh .SH NAME __gnu_parallel::_LoserTreeBase< _Tp, _Compare > \- Guarded loser/tournament tree\&. .SH SYNOPSIS .br .PP .PP Inherited by \fB__gnu_parallel::_LoserTree< __stable, _Tp, _Compare >\fP, and \fB__gnu_parallel::_LoserTree< false, _Tp, _Compare >\fP\&. .SS "Classes" .in +1c .ti -1c .RI "struct \fB_Loser\fP" .br .RI "Internal representation of a _LoserTree element\&. " .in -1c .SS "Public Member Functions" .in +1c .ti -1c .RI "\fB_LoserTreeBase\fP (unsigned int __k, _Compare __comp)" .br .RI "The constructor\&. " .ti -1c .RI "\fB~_LoserTreeBase\fP ()" .br .RI "The destructor\&. " .ti -1c .RI "int \fB__get_min_source\fP ()" .br .ti -1c .RI "void \fB__insert_start\fP (const _Tp &__key, int __source, bool __sup)" .br .RI "Initializes the sequence '_M_source' with the element '__key'\&. " .in -1c .SS "Protected Attributes" .in +1c .ti -1c .RI "_Compare \fB_M_comp\fP" .br .RI "_Compare to use\&. " .ti -1c .RI "bool \fB_M_first_insert\fP" .br .RI "State flag that determines whether the _LoserTree is empty\&. " .ti -1c .RI "unsigned int \fB_M_ik\fP" .br .ti -1c .RI "unsigned int \fB_M_k\fP" .br .ti -1c .RI "unsigned int \fB_M_log_k\fP" .br .ti -1c .RI "\fB_Loser\fP * \fB_M_losers\fP" .br .RI "_LoserTree __elements\&. " .ti -1c .RI "unsigned int \fB_M_offset\fP" .br .in -1c .SH "Detailed Description" .PP .SS "template .br class __gnu_parallel::_LoserTreeBase< _Tp, _Compare >" Guarded loser/tournament tree\&. The smallest element is at the top\&. .PP Guarding is done explicitly through one flag _M_sup per element, inf is not needed due to a better initialization routine\&. This is a well-performing variant\&. .PP \fBParameters\fP .RS 4 \fI_Tp\fP the element type .br \fI_Compare\fP the comparator to use, defaults to std::less<_Tp> .RE .PP .PP Definition at line 55 of file losertree\&.h\&. .SH "Constructor & Destructor Documentation" .PP .SS "template \fB__gnu_parallel::_LoserTreeBase\fP< _Tp, _Compare >::\fB_LoserTreeBase\fP (unsigned int __k, _Compare __comp)\fC [inline]\fP" .PP The constructor\&. .PP \fBParameters\fP .RS 4 \fI__k\fP The number of sequences to merge\&. .br \fI__comp\fP The comparator to use\&. .RE .PP .PP Definition at line 94 of file losertree\&.h\&. .PP References __gnu_parallel::__rd_log2(), __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_M_first_insert, __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_M_log_k, and __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_M_losers\&. .SS "template \fB__gnu_parallel::_LoserTreeBase\fP< _Tp, _Compare >::~\fB_LoserTreeBase\fP ()\fC [inline]\fP" .PP The destructor\&. .PP Definition at line 118 of file losertree\&.h\&. .PP References __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_M_losers\&. .SH "Member Function Documentation" .PP .SS "template int \fB__gnu_parallel::_LoserTreeBase\fP< _Tp, _Compare >::__get_min_source ()\fC [inline]\fP" .PP \fBReturns\fP .RS 4 the index of the sequence with the smallest element\&. .RE .PP .PP Definition at line 155 of file losertree\&.h\&. .PP References __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_M_losers, and __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_Loser::_M_source\&. .SS "template void \fB__gnu_parallel::_LoserTreeBase\fP< _Tp, _Compare >::__insert_start (const _Tp & __key, int __source, bool __sup)\fC [inline]\fP" .PP Initializes the sequence '_M_source' with the element '__key'\&. .PP \fBParameters\fP .RS 4 \fI__key\fP the element to insert .br \fI__source\fP __index of the __source __sequence .br \fI__sup\fP flag that determines whether the value to insert is an explicit __supremum\&. .RE .PP .PP Definition at line 134 of file losertree\&.h\&. .PP References __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_M_first_insert, __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_Loser::_M_key, __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_M_losers, __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_Loser::_M_source, and __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_Loser::_M_sup\&. .SH "Member Data Documentation" .PP .SS "template _Compare \fB__gnu_parallel::_LoserTreeBase\fP< _Tp, _Compare >::_M_comp\fC [protected]\fP" .PP _Compare to use\&. .PP Definition at line 78 of file losertree\&.h\&. .SS "template bool \fB__gnu_parallel::_LoserTreeBase\fP< _Tp, _Compare >::_M_first_insert\fC [protected]\fP" .PP State flag that determines whether the _LoserTree is empty\&. Only used for building the _LoserTree\&. .PP Definition at line 85 of file losertree\&.h\&. .PP Referenced by __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_LoserTreeBase(), and __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::__insert_start()\&. .SS "template unsigned int \fB__gnu_parallel::_LoserTreeBase\fP< _Tp, _Compare >::_M_log_k\fC [protected]\fP" log_2{_M_k} .PP Definition at line 72 of file losertree\&.h\&. .PP Referenced by __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_LoserTreeBase()\&. .SS "template \fB_Loser\fP* \fB__gnu_parallel::_LoserTreeBase\fP< _Tp, _Compare >::_M_losers\fC [protected]\fP" .PP _LoserTree __elements\&. .PP Definition at line 75 of file losertree\&.h\&. .PP Referenced by __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::_LoserTreeBase(), __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::~_LoserTreeBase(), __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::__get_min_source(), and __gnu_parallel::_LoserTreeBase< _Tp, _Compare >::__insert_start()\&. .SH "Author" .PP Generated automatically by Doxygen for libstdc++ from the source code\&.