![]() |
C++ Library Extensions 2022.12.09
To help learn modern C++ programming
|
Typedefs | |
template<typename T > | |
using | range = std::pair< T, T > |
typedef range< size_t > | range_t |
template<typename T > | |
using | rngvctr = std::deque< range< T > > |
typedef rngvctr< size_t > | range_vctr_t |
Functions | |
template<typename T > | |
std::string | display_range (const range< T > &rg, bool thousands=true) |
template<typename T > | |
rngvctr< T > | split_range_count (T st, T ed, T count=(T)(-1)) |
template<typename T > | |
rngvctr< T > | split_range_span (T st, T ed, T min_span=(T)(-1)) |
template<typename T > | |
std::string | display_ranges (const rngvctr< T > &rngs, int width=9, bool thousands=true) |
size_t | cpu_thread_count () noexcept |
template<typename T > | |
rngvctr< T > | split_range_half (T st, T ed) |
template<typename RangeType , typename BinOperation , typename SumupOperation , typename = std::enable_if_t<tpf::types::is_integer_v<RangeType>>> | |
auto | parallel_reduce (RangeType start, RangeType end, BinOperation &&bin_opr, SumupOperation &&sumup, size_t use_thread_count=tpf::InvalidIndex) |
template<typename ContainerType , typename BinOperation , typename SumupOperation , typename = tpf::types::enable_if_container_type_t<ContainerType>> | |
auto | parallel_reduce (ContainerType &&container, BinOperation &&bin_opr, SumupOperation &&sumup, size_t use_thread_count=tpf::InvalidIndex) |
using tpf::split_range::range = typedef std::pair<T, T> |
Definition at line 41 of file tpf_split_ranges.hpp.
typedef range<size_t> tpf::split_range::range_t |
Definition at line 43 of file tpf_split_ranges.hpp.
typedef rngvctr<size_t> tpf::split_range::range_vctr_t |
Definition at line 48 of file tpf_split_ranges.hpp.
using tpf::split_range::rngvctr = typedef std::deque<range<T> > |
Definition at line 46 of file tpf_split_ranges.hpp.
|
inlinenoexcept |
std::string tpf::split_range::display_range | ( | const range< T > & | rg, |
bool | thousands = true |
||
) |
Definition at line 51 of file tpf_split_ranges.hpp.
std::string tpf::split_range::display_ranges | ( | const rngvctr< T > & | rngs, |
int | width = 9 , |
||
bool | thousands = true |
||
) |
Definition at line 197 of file tpf_split_ranges.hpp.
auto tpf::split_range::parallel_reduce | ( | ContainerType && | container, |
BinOperation && | bin_opr, | ||
SumupOperation && | sumup, | ||
size_t | use_thread_count = tpf::InvalidIndex |
||
) |
auto tpf::split_range::parallel_reduce | ( | RangeType | start, |
RangeType | end, | ||
BinOperation && | bin_opr, | ||
SumupOperation && | sumup, | ||
size_t | use_thread_count = tpf::InvalidIndex |
||
) |
Definition at line 235 of file tpf_split_ranges.hpp.
rngvctr< T > tpf::split_range::split_range_count | ( | T | st, |
T | ed, | ||
T | count = (T)(-1) |
||
) |
Definition at line 142 of file tpf_split_ranges.hpp.
rngvctr< T > tpf::split_range::split_range_half | ( | T | st, |
T | ed | ||
) |
rngvctr< T > tpf::split_range::split_range_span | ( | T | st, |
T | ed, | ||
T | min_span = (T)(-1) |
||
) |