std::experimental::simd

From cppreference.com
< cpplrm; | experimentallrm; | simd
Technical specifications
Filesystem library (filesystem TS)
Library fundamentals (library fundamentals TS)
Library fundamentals 2 (library fundamentals 2 TS)
Extensions for parallelism (parallelism TS)
Extensions for parallelism 2 (parallelism TS v2)
Extensions for concurrency (concurrency TS)
Concepts (concepts TS)
Ranges (ranges TS)
Special mathematical functions (special math TR)
Defined in header <experimental/simd>
template< class T, class Abi = simd_abi::compatible<T> >
class simd;

The class template simd is a data-parallel type. The width of a given simd instantiation is a constant expression, determined by the template parameters.

An ABI tag is a type in the simd_abi namespace that indicates a choice of size and binary representation for objects of data-parallel type.

Template parameters

T - element type
Abi - tag type used to determine the number of elements and storage

Helper alias templates

template< class T, int N >
using fixed_size_simd = std::experimental::simd<T, std::experimental::simd_abi::fixed_size<N>>;
template< class T, int N >
using native_simd = std::experimental::simd<T, std::experimental::simd_abi::native>;

Member types

Member type Definition
value_type T
reference implementation-defined
mask_type simd_mask<T, Abi>
abi_type Abi

Member functions

constructs a simd object
(public member function)
loads from address
(public member function)
stores to address
(public member function)
accesses specified element
(public member function)
element-wise increment and decrement
(public member function)
element-wise unary operators
(public member function)
[static]
returns the number of elements
(public static member function)

Non-member functions

element-wise binary operators
(function)
element-wise compound binary operators
(function)
element-wise relational operators
(function)

Example