|
SeqAn3 3.4.2-rc.1
The Modern C++ library for sequence analysis.
|
Implements a special version of a counted iterator over a simd vector. More...
#include <seqan3/utility/simd/views/iota_simd.hpp>
Inheritance diagram for seqan3::detail::counted_simd_iterator< index_simd_t >:Public Types | |
Associated types | |
| using | value_type = index_simd_t |
| The value type. | |
| using | reference = value_type |
| The reference type. | |
| using | pointer = void |
| The pointer type. | |
| using | difference_type = std::ptrdiff_t |
| The difference type. | |
| using | iterator_category = std::forward_iterator_tag |
| The iterator category. | |
Public Member Functions | |
Constructor, assignment and destructor | |
| counted_simd_iterator ()=default | |
| Defaulted. | |
| counted_simd_iterator (counted_simd_iterator const &)=default | |
| Defaulted. | |
| counted_simd_iterator (counted_simd_iterator &&)=default | |
| Defaulted. | |
| counted_simd_iterator & | operator= (counted_simd_iterator const &)=default |
| Defaulted. | |
| counted_simd_iterator & | operator= (counted_simd_iterator &&)=default |
| Defaulted. | |
| ~counted_simd_iterator ()=default | |
| Defaulted. | |
| template<arithmetic index_scalar_t> | |
| counted_simd_iterator (index_scalar_t const scalar_index) noexcept | |
| Constructs and initialises the iterator with the given index. | |
Element access | |
| reference | operator* () const |
| Return the current simd index. | |
Arithmetic operators | |
| counted_simd_iterator & | operator++ () |
| Increments the iterator. | |
| counted_simd_iterator | operator++ (int) |
| Increments the iterator and returns the iterator pointing to the previous index. | |
| difference_type | operator- (counted_simd_iterator const &rhs) const |
| Returns the distance between two iterators. | |
Private Attributes | |
| index_simd_t | count_simd {} |
| The currently represented count. | |
Friends | |
Comparison operators | |
| bool | operator== (counted_simd_iterator const &lhs, counted_simd_iterator const &rhs) noexcept |
Tests whether lhs == rhs. | |
| bool | operator!= (counted_simd_iterator const &lhs, counted_simd_iterator const &rhs) noexcept |
Tests whether lhs != rhs. | |
Implements a special version of a counted iterator over a simd vector.
| index_simd_t | The type of the index; must model seqan3::simd::simd_concept. |
Uses a simd count vector to increment the counted iterator. This seems to be in general faster than calling seqan3::simd::fill when dereferencing the iterator, although this is just a constant and fast operation.
|
inlineexplicitnoexcept |
Constructs and initialises the iterator with the given index.
| index_scalar_t | The scalar index type; must model seqan3::arithmetic. |
| [in] | scalar_index | The scalar index the iterator shall represent. |