The simd module contains a unified interface to provide simd types and functions used in seqan3.
More...
|
template<typename scalar_t , size_t length = detail::default_simd_length<scalar_t, detail::default_simd_backend>, typename simd_backend = detail::default_simd_backend<scalar_t, length>> |
using | seqan3::simd::simd_type_t = typename simd_type< scalar_t, length, simd_backend >::type |
| Helper type of seqan3::simd::simd_type.
|
|
The simd module contains a unified interface to provide simd types and functions used in seqan3.
- See also
- https://en.wikipedia.org/wiki/SIMD
There are different simd implementations (backends), which are auto-selected by seqan3::simd::simd_type_t.
◆ fill()
template<simd_concept simd_t>
constexpr simd_t seqan3::simd::fill |
( |
typename simd_traits< simd_t >::scalar_type const |
scalar | ) |
|
Fills a seqan3::simd::simd_type vector with a scalar value.
- Template Parameters
-
- Parameters
-
using uint8x16_t = simd_type_t<uint16_t, 8>;
int main()
{
uint8x16_t a = fill<uint8x16_t>(4);
uint8x16_t b = simd::fill<uint8x16_t>(4);
return 0;
}
◆ iota()
template<simd_concept simd_t>
constexpr simd_t seqan3::simd::iota |
( |
typename simd_traits< simd_t >::scalar_type const |
offset | ) |
|
Fills a seqan3::simd::simd_type vector with the scalar values offset, offset+1, offset+2, ...
- Template Parameters
-
- Parameters
-
using uint8x16_t = simd_type_t<uint16_t, 8>;
int main()
{
uint8x16_t a = iota<uint8x16_t>(1);
uint8x16_t b = simd::iota<uint8x16_t>(1);
return 0;
}