![]() |
Blaze 3.9
|
Implementation of a generic iterator for dense vectors and matrices. More...
#include <DenseIterator.h>
Public Types | |
using | IteratorCategory = std::random_access_iterator_tag |
The iterator category. | |
using | ValueType = Type |
Type of the underlying elements. | |
using | PointerType = Type * |
Pointer return type. | |
using | ReferenceType = Type & |
Reference return type. | |
using | DifferenceType = ptrdiff_t |
Difference between two iterators. | |
using | iterator_category = IteratorCategory |
The iterator category. | |
using | value_type = ValueType |
Type of the underlying elements. | |
using | pointer = PointerType |
Pointer return type. | |
using | reference = ReferenceType |
Reference return type. | |
using | difference_type = DifferenceType |
Difference between two iterators. | |
using | SIMDType = SIMDTrait_t< Type > |
SIMD type of the elements. | |
Public Member Functions | |
Constructors | |
constexpr | DenseIterator () noexcept |
Default constructor for the DenseIterator class. | |
constexpr | DenseIterator (Type *ptr) noexcept |
Constructor for the DenseIterator class. More... | |
template<typename Other , AlignmentFlag AF2> | |
constexpr | DenseIterator (const DenseIterator< Other, AF2 > &it) noexcept |
Conversion constructor from different DenseIterator instances. More... | |
DenseIterator (const DenseIterator &)=default | |
Destructor | |
~DenseIterator ()=default | |
Assignment operators | |
constexpr DenseIterator & | operator+= (ptrdiff_t inc) noexcept |
Addition assignment operator. More... | |
constexpr DenseIterator & | operator-= (ptrdiff_t inc) noexcept |
Subtraction assignment operator. More... | |
DenseIterator & | operator= (const DenseIterator &)=default |
Increment/decrement operators | |
constexpr DenseIterator & | operator++ () noexcept |
Pre-increment operator. More... | |
constexpr const DenseIterator | operator++ (int) noexcept |
Post-increment operator. More... | |
constexpr DenseIterator & | operator-- () noexcept |
Pre-decrement operator. More... | |
constexpr const DenseIterator | operator-- (int) noexcept |
Post-decrement operator. More... | |
Access operators | |
constexpr ReferenceType | operator[] (size_t index) const noexcept |
Direct access to the underlying elements. More... | |
constexpr ReferenceType | operator* () const noexcept |
Direct access to the element at the current iterator position. More... | |
constexpr PointerType | operator-> () const noexcept |
Direct access to the element at the current iterator position. More... | |
Utility functions | |
constexpr PointerType | base () const noexcept |
Low-level access to the underlying member of the iterator. More... | |
Expression template evaluation functions | |
const SIMDType | load () const noexcept |
Load of the SIMD element at the current iterator position. More... | |
const SIMDType | loada () const noexcept |
Aligned load of the SIMD element at the current iterator position. More... | |
const SIMDType | loadu () const noexcept |
Unaligned load of the SIMD element at the current iterator position. More... | |
void | store (const SIMDType &value) const noexcept |
Store of the SIMD element at the current iterator position. More... | |
void | storea (const SIMDType &value) const noexcept |
Aligned store of the SIMD element at the current iterator position. More... | |
void | storeu (const SIMDType &value) const noexcept |
Unaligned store of the SIMD element at the current iterator position. More... | |
void | stream (const SIMDType &value) const noexcept |
Aligned, non-temporal store of the SIMD element at the current iterator position. More... | |
Private Attributes | |
Member variables | |
PointerType | ptr_ |
Pointer to the current element. | |
Implementation of a generic iterator for dense vectors and matrices.
The DenseIterator represents a generic random-access iterator that can be used for dense vectors and specific rows/columns of dense matrices.
|
explicitconstexprnoexcept |
Constructor for the DenseIterator class.
ptr | Pointer to the initial element. |
|
constexprnoexcept |
Conversion constructor from different DenseIterator instances.
it | The foreign DenseIterator instance to be copied. |
|
constexprnoexcept |
Low-level access to the underlying member of the iterator.
|
inlinenoexcept |
Load of the SIMD element at the current iterator position.
This function performs a load of the SIMD element of the current element. This function must NOT be called explicitly! It is used internally for the performance optimized evaluation of expression templates. Calling this function explicitly might result in erroneous results and/or in compilation errors.
|
inlinenoexcept |
Aligned load of the SIMD element at the current iterator position.
This function performs an aligned load of the SIMD element of the current element. This function must NOT be called explicitly! It is used internally for the performance optimized evaluation of expression templates. Calling this function explicitly might result in erroneous results and/or in compilation errors.
|
inlinenoexcept |
Unaligned load of the SIMD element at the current iterator position.
This function performs an unaligned load of the SIMD element of the current element. This function must NOT be called explicitly! It is used internally for the performance optimized evaluation of expression templates. Calling this function explicitly might result in erroneous results and/or in compilation errors.
|
constexprnoexcept |
Direct access to the element at the current iterator position.
|
constexprnoexcept |
Pre-increment operator.
|
constexprnoexcept |
Post-increment operator.
|
constexprnoexcept |
Addition assignment operator.
inc | The increment of the iterator. |
|
constexprnoexcept |
Pre-decrement operator.
|
constexprnoexcept |
Post-decrement operator.
|
constexprnoexcept |
Subtraction assignment operator.
dec | The decrement of the iterator. |
|
constexprnoexcept |
Direct access to the element at the current iterator position.
|
constexprnoexcept |
Direct access to the underlying elements.
index | Access index. |
|
inlinenoexcept |
Store of the SIMD element at the current iterator position.
value | The SIMD element to be stored. |
This function performs a store of the SIMD element of the current element. This function must NOT be called explicitly! It is used internally for the performance optimized evaluation of expression templates. Calling this function explicitly might result in erroneous results and/or in compilation errors.
|
inlinenoexcept |
Aligned store of the SIMD element at the current iterator position.
value | The SIMD element to be stored. |
This function performs an aligned store of the SIMD element of the current element. This function must NOT be called explicitly! It is used internally for the performance optimized evaluation of expression templates. Calling this function explicitly might result in erroneous results and/or in compilation errors.
|
inlinenoexcept |
Unaligned store of the SIMD element at the current iterator position.
value | The SIMD element to be stored. |
This function performs an unaligned store of the SIMD element of the current element. This function must NOT be called explicitly! It is used internally for the performance optimized evaluation of expression templates. Calling this function explicitly might result in erroneous results and/or in compilation errors.
|
inlinenoexcept |
Aligned, non-temporal store of the SIMD element at the current iterator position.
value | The SIMD element to be stored. |
This function performs an aligned, non-temporal store of the SIMD element of the current element. This function must NOT be called explicitly! It is used internally for the performance optimized evaluation of expression templates. Calling this function explicitly might result in erroneous results and/or in compilation errors.