|
Thread System 0.3.1
High-performance C++20 thread pool with work stealing and DAG scheduling
|
A fallback span implementation for C++17 and earlier compilers. More...
#include <span.h>

Public Types | |
| using | element_type = T |
| using | value_type = std::remove_cv_t<T> |
| using | size_type = size_t |
| using | difference_type = ptrdiff_t |
| using | pointer = T* |
| using | const_pointer = const T* |
| using | reference = T& |
| using | const_reference = const T& |
| using | iterator = pointer |
| using | const_iterator = const_pointer |
| using | reverse_iterator = std::reverse_iterator<iterator> |
| using | const_reverse_iterator = std::reverse_iterator<const_iterator> |
Public Member Functions | |
| constexpr | span () noexcept |
| constexpr | span (pointer ptr, size_type count) noexcept |
| constexpr | span (pointer first, pointer last) noexcept |
| template<size_t N> | |
| constexpr | span (std::array< value_type, N > &arr) noexcept |
| template<size_t N> | |
| constexpr | span (const std::array< value_type, N > &arr) noexcept |
| template<typename Allocator > | |
| constexpr | span (std::vector< value_type, Allocator > &vec) noexcept |
| template<typename Allocator > | |
| constexpr | span (const std::vector< value_type, Allocator > &vec) noexcept |
| template<size_t N> | |
| constexpr | span (element_type(&arr)[N]) noexcept |
| constexpr span & | operator= (const span &other) noexcept=default |
| constexpr size_type | size () const noexcept |
| constexpr size_type | size_bytes () const noexcept |
| constexpr bool | empty () const noexcept |
| constexpr reference | operator[] (size_type idx) const noexcept |
| constexpr reference | front () const noexcept |
| constexpr reference | back () const noexcept |
| constexpr pointer | data () const noexcept |
| constexpr iterator | begin () const noexcept |
| constexpr iterator | end () const noexcept |
| constexpr const_iterator | cbegin () const noexcept |
| constexpr const_iterator | cend () const noexcept |
| constexpr reverse_iterator | rbegin () const noexcept |
| constexpr reverse_iterator | rend () const noexcept |
| constexpr const_reverse_iterator | crbegin () const noexcept |
| constexpr const_reverse_iterator | crend () const noexcept |
| template<size_t Count> | |
| constexpr span< element_type, Count > | first () const noexcept |
| constexpr span< element_type, dynamic_extent > | first (size_type count) const noexcept |
| template<size_t Count> | |
| constexpr span< element_type, Count > | last () const noexcept |
| constexpr span< element_type, dynamic_extent > | last (size_type count) const noexcept |
| template<size_t Offset, size_t Count = dynamic_extent> | |
| constexpr auto | subspan () const noexcept |
| constexpr span< element_type, dynamic_extent > | subspan (size_type offset, size_type count=dynamic_extent) const noexcept |
| constexpr | span () noexcept |
| constexpr | span (pointer ptr, size_type count) noexcept |
| constexpr | span (pointer first, pointer last) noexcept |
| template<size_t N> | |
| constexpr | span (std::array< value_type, N > &arr) noexcept |
| template<size_t N> | |
| constexpr | span (const std::array< value_type, N > &arr) noexcept |
| template<typename Allocator > | |
| constexpr | span (std::vector< value_type, Allocator > &vec) noexcept |
| template<typename Allocator > | |
| constexpr | span (const std::vector< value_type, Allocator > &vec) noexcept |
| template<size_t N> | |
| constexpr | span (element_type(&arr)[N]) noexcept |
| constexpr span & | operator= (const span &other) noexcept=default |
| constexpr size_type | size () const noexcept |
| constexpr size_type | size_bytes () const noexcept |
| constexpr bool | empty () const noexcept |
| constexpr reference | operator[] (size_type idx) const noexcept |
| constexpr reference | front () const noexcept |
| constexpr reference | back () const noexcept |
| constexpr pointer | data () const noexcept |
| constexpr iterator | begin () const noexcept |
| constexpr iterator | end () const noexcept |
| constexpr const_iterator | cbegin () const noexcept |
| constexpr const_iterator | cend () const noexcept |
| constexpr reverse_iterator | rbegin () const noexcept |
| constexpr reverse_iterator | rend () const noexcept |
| constexpr const_reverse_iterator | crbegin () const noexcept |
| constexpr const_reverse_iterator | crend () const noexcept |
| template<size_t Count> | |
| constexpr span< element_type, Count > | first () const noexcept |
| constexpr span< element_type, dynamic_extent > | first (size_type count) const noexcept |
| template<size_t Count> | |
| constexpr span< element_type, Count > | last () const noexcept |
| constexpr span< element_type, dynamic_extent > | last (size_type count) const noexcept |
| template<size_t Offset, size_t Count = dynamic_extent> | |
| constexpr auto | subspan () const noexcept |
| constexpr span< element_type, dynamic_extent > | subspan (size_type offset, size_type count=dynamic_extent) const noexcept |
Static Public Attributes | |
| static constexpr size_t | dynamic_extent = size_t(-1) |
Private Attributes | |
| pointer | data_ |
| size_type | size_ |
A fallback span implementation for C++17 and earlier compilers.
Provides a view over a contiguous sequence of objects, similar to C++20's std::span. This implementation offers a compatible subset of the std::span interface.
| T | The type of elements in the span. |
| Extent | The extent (size) of the span, or dynamic_extent if determined at runtime. |
| typedef const_pointer kcenon::thread::utils::span::const_iterator = const_pointer |
| typedef const T * kcenon::thread::utils::span::const_pointer = const T* |
| typedef const T & kcenon::thread::utils::span::const_reference = const T& |
| typedef std::reverse_iterator< const_iterator > kcenon::thread::utils::span::const_reverse_iterator = std::reverse_iterator<const_iterator> |
| typedef ptrdiff_t kcenon::thread::utils::span::difference_type = ptrdiff_t |
| typedef T kcenon::thread::utils::span::element_type = T |
| typedef T * kcenon::thread::utils::span::pointer = T* |
| typedef T & kcenon::thread::utils::span::reference = T& |
| typedef size_t kcenon::thread::utils::span::size_type = size_t |
| typedef std::remove_cv_t< T > kcenon::thread::utils::span::value_type = std::remove_cv_t<T> |
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
Definition at line 66 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 72 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 80 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 88 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 97 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 105 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 114 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
Definition at line 72 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 78 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 86 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 94 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 103 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 111 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlineconstexprnoexcept |
Definition at line 120 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlinenodiscardconstexprnoexcept |
Definition at line 146 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlinenodiscardconstexprnoexcept |
Definition at line 140 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
Definition at line 148 of file span.h.
References utility_module::span< T, Extent >::data_.
Referenced by utility_module::span< T, Extent >::rend().

|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
Definition at line 150 of file span.h.
References utility_module::span< T, Extent >::data_.
Referenced by utility_module::span< T, Extent >::crend().

|
inlinenodiscardconstexprnoexcept |
Definition at line 157 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlinenodiscardconstexprnoexcept |
Definition at line 151 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
Referenced by utility_module::span< T, Extent >::crbegin().

|
inlinenodiscardconstexprnoexcept |
Definition at line 160 of file span.h.
References utility_module::span< T, Extent >::cend().

|
inlinenodiscardconstexprnoexcept |
Definition at line 154 of file span.h.
References utility_module::span< T, Extent >::cend().

|
inlinenodiscardconstexprnoexcept |
Definition at line 161 of file span.h.
References utility_module::span< T, Extent >::cbegin().

|
inlinenodiscardconstexprnoexcept |
Definition at line 155 of file span.h.
References utility_module::span< T, Extent >::cbegin().

|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
Definition at line 155 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
|
inlinenodiscardconstexprnoexcept |
Definition at line 149 of file span.h.
References utility_module::span< T, Extent >::data_, and utility_module::span< T, Extent >::size_.
Referenced by utility_module::span< T, Extent >::rbegin().

|
inlinenodiscardconstexprnoexcept |
Definition at line 165 of file span.h.
References utility_module::span< T, Extent >::data_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 159 of file span.h.
References utility_module::span< T, Extent >::data_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 170 of file span.h.
References utility_module::span< T, Extent >::data_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 164 of file span.h.
References utility_module::span< T, Extent >::data_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 141 of file span.h.
References utility_module::span< T, Extent >::data_.
|
inlinenodiscardconstexprnoexcept |
Definition at line 135 of file span.h.
References utility_module::span< T, Extent >::data_.
|
inlinenodiscardconstexprnoexcept |
Definition at line 176 of file span.h.
References utility_module::span< T, Extent >::data_, utility_module::span< T, Extent >::size_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 170 of file span.h.
References utility_module::span< T, Extent >::data_, utility_module::span< T, Extent >::size_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 181 of file span.h.
References utility_module::span< T, Extent >::data_, utility_module::span< T, Extent >::size_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 175 of file span.h.
References utility_module::span< T, Extent >::data_, utility_module::span< T, Extent >::size_, and kcenon::thread::utils::span().

|
constexprdefaultnoexcept |
|
constexprdefaultnoexcept |
|
inlinenodiscardconstexprnoexcept |
Definition at line 136 of file span.h.
References utility_module::span< T, Extent >::data_.
|
inlinenodiscardconstexprnoexcept |
Definition at line 130 of file span.h.
References utility_module::span< T, Extent >::data_.
|
inlinenodiscardconstexprnoexcept |
Definition at line 158 of file span.h.
References utility_module::span< T, Extent >::end().

|
inlinenodiscardconstexprnoexcept |
Definition at line 152 of file span.h.
References utility_module::span< T, Extent >::end().

|
inlinenodiscardconstexprnoexcept |
Definition at line 159 of file span.h.
References utility_module::span< T, Extent >::begin().

|
inlinenodiscardconstexprnoexcept |
Definition at line 153 of file span.h.
References utility_module::span< T, Extent >::begin().

|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
|
inlinenodiscardconstexprnoexcept |
Definition at line 187 of file span.h.
References utility_module::span< T, Extent >::data_, utility_module::span< T, Extent >::size_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 181 of file span.h.
References utility_module::span< T, Extent >::data_, utility_module::span< T, Extent >::size_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 197 of file span.h.
References utility_module::span< T, Extent >::data_, utility_module::span< T, Extent >::size_, and kcenon::thread::utils::span().

|
inlinenodiscardconstexprnoexcept |
Definition at line 191 of file span.h.
References utility_module::span< T, Extent >::data_, utility_module::span< T, Extent >::size_, and kcenon::thread::utils::span().

|
private |
Definition at line 198 of file span.h.
Referenced by utility_module::span< T, Extent >::back(), utility_module::span< T, Extent >::begin(), utility_module::span< T, Extent >::cbegin(), utility_module::span< T, Extent >::cend(), utility_module::span< T, Extent >::data(), utility_module::span< T, Extent >::end(), utility_module::span< T, Extent >::first(), utility_module::span< T, Extent >::first(), utility_module::span< T, Extent >::front(), utility_module::span< T, Extent >::last(), utility_module::span< T, Extent >::last(), utility_module::span< T, Extent >::operator[](), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::subspan(), and utility_module::span< T, Extent >::subspan().
|
staticconstexpr |
|
private |
Definition at line 199 of file span.h.
Referenced by utility_module::span< T, Extent >::back(), utility_module::span< T, Extent >::cend(), utility_module::span< T, Extent >::empty(), utility_module::span< T, Extent >::end(), utility_module::span< T, Extent >::last(), utility_module::span< T, Extent >::last(), utility_module::span< T, Extent >::size(), utility_module::span< T, Extent >::size_bytes(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::span(), utility_module::span< T, Extent >::subspan(), and utility_module::span< T, Extent >::subspan().