AI Engine API User Guide (AIE) 2023.2
|
Operations to initialize vectors and accumulators. More...
Operations to initialize vectors and accumulators.
Functions | |
template<Elem E, unsigned Elems = native_vector_length_v<E>> | |
vector< operand_base_type_t< E >, Elems > | aie::broadcast (E a) |
Returns a vector whose elements are initialized to the given value. | |
template<Accum Acc, Accum... Accums> requires ((is_same_accum_v<Acc, Accums> && ...)) | |
auto | aie::concat (const Acc &acc, const Accums &...accums) -> accum< typename Acc::value_type, Acc::size() *(1+sizeof...(Accums))> |
Concatenate the contents of all input accumulators into a larger accumulator. | |
template<Vector Vec, Vector... Vectors> requires ((is_same_vector_v<Vec, Vectors> && ...)) | |
auto | aie::concat (const Vec &v, const Vectors &...vectors) -> vector< typename Vec::value_type, Vec::size() *(1+sizeof...(Vectors))> |
Concatenate the contents of all input vectors into a larger vector. | |
template<ElemBaseType T, unsigned Elems = native_vector_length_v<T>> | |
vector< T, Elems > | aie::zeros () |
Returns a vector whose elements are initialized to zero. | |
vector< operand_base_type_t< E >, Elems > aie::broadcast | ( | E | a | ) |
Returns a vector whose elements are initialized to the given value.
E. | Element type of the returned vector. |
Elems. | Size of the vector. |
a | Value. The type must meet Elem. |
auto aie::concat | ( | const Acc & | acc, |
const Accums &... | accums | ||
) | -> accum<typename Acc::value_type, Acc::size() * (1 + sizeof...(Accums))> |
Concatenate the contents of all input accumulators into a larger accumulator.
All input accumulators must have the same type and size.
acc | First input accumulator. |
accums | Rest of input accumulators. |
auto aie::concat | ( | const Vec & | v, |
const Vectors &... | vectors | ||
) | -> vector<typename Vec::value_type, Vec::size() * (1 + sizeof...(Vectors))> |
Concatenate the contents of all input vectors into a larger vector.
All input vectors must have the same type and size.
v | First input vector. |
vectors | Rest of input vectors. |
vector< T, Elems > aie::zeros | ( | ) |
Returns a vector whose elements are initialized to zero.
E. | Element type of the returned vector. |
Elems. | Size of the vector. |