T-SIMD v31.1.0
A C++ template SIMD library
Loading...
Searching...
No Matches
Elementwise Shifting

Description

Functions for shifting a Vec elementwise.

Functions

template<size_t COUNT, typename T , size_t SIMD_WIDTH>
static Vec< T, SIMD_WIDTH > simd::alignre (const Vec< T, SIMD_WIDTH > &h, const Vec< T, SIMD_WIDTH > &l)
 Concatenates two Vec's, shifts the result right by a constant number of elements, and returns the low half of the result.
 
template<size_t COUNT, typename T , size_t SIMD_WIDTH>
static Vec< T, SIMD_WIDTH > simd::slle (const Vec< T, SIMD_WIDTH > &a)
 Shifts a Vec left by a constant number of elements, shifting in zero elements.
 
template<size_t COUNT, typename T , size_t SIMD_WIDTH>
static Vec< T, SIMD_WIDTH > simd::srle (const Vec< T, SIMD_WIDTH > &a)
 Shifts a Vec right by a constant number of elements, shifting in zero elements.
 

Function Documentation

◆ alignre()

template<size_t COUNT, typename T , size_t SIMD_WIDTH>
static Vec< T, SIMD_WIDTH > simd::alignre ( const Vec< T, SIMD_WIDTH > & h,
const Vec< T, SIMD_WIDTH > & l )
inlinestatic

Concatenates two Vec's, shifts the result right by a constant number of elements, and returns the low half of the result.

Template Parameters
COUNTnumber of elements to shift by
Parameters
hfirst Vec The high half of the concatenated Vec
lsecond Vec The low half of the concatenated Vec
Returns
low half of the shifted concatenated Vec

◆ slle()

template<size_t COUNT, typename T , size_t SIMD_WIDTH>
static Vec< T, SIMD_WIDTH > simd::slle ( const Vec< T, SIMD_WIDTH > & a)
inlinestatic

Shifts a Vec left by a constant number of elements, shifting in zero elements.

Template Parameters
COUNTnumber of elements to shift by
Parameters
aVec to shift
Returns
shifted Vec

◆ srle()

template<size_t COUNT, typename T , size_t SIMD_WIDTH>
static Vec< T, SIMD_WIDTH > simd::srle ( const Vec< T, SIMD_WIDTH > & a)
inlinestatic

Shifts a Vec right by a constant number of elements, shifting in zero elements.

Template Parameters
COUNTnumber of elements to shift by
Parameters
aVec to shift
Returns
shifted Vec