T-SIMD v31.1.0
A C++ template SIMD library
Loading...
Searching...
No Matches
simd::HAccStore< HOp, T, SIMD_WIDTH > Class Template Reference

Iterative horizontal accumulator with store of the result. Calculates the horizontal accumulation of multiple Vec's in parallel with the Vec's to be accumulated pushed one by one. Stores the result of the horizontal accumulation every Vec<T, SIMD_WIDTH>::elems Vec's into memory. More...

Detailed Description

template<class HOp, typename T, size_t SIMD_WIDTH>
class simd::HAccStore< HOp, T, SIMD_WIDTH >

Iterative horizontal accumulator with store of the result. Calculates the horizontal accumulation of multiple Vec's in parallel with the Vec's to be accumulated pushed one by one. Stores the result of the horizontal accumulation every Vec<T, SIMD_WIDTH>::elems Vec's into memory.

Template Parameters
HOphorizontal accumulation operation, one of HAdd, HAdds, HMin, HMax

Public Member Functions

void finish ()
 Finishes the horizontal accumulation and stores the result of the horizontal accumulation into memory.
 
 HAccStore (T *const p)
 Constructs a new HAccStore object.
 
void push (Vec< T, SIMD_WIDTH > v)
 Pushes the next Vec to be horizontally accumulated. Stores the result of the horizontal accumulation every Vec<T, SIMD_WIDTH>::elems Vec's into memory.
 

Constructor & Destructor Documentation

◆ HAccStore()

template<class HOp , typename T , size_t SIMD_WIDTH>
simd::HAccStore< HOp, T, SIMD_WIDTH >::HAccStore ( T *const p)
inline

Constructs a new HAccStore object.

Parameters
ppointer to the memory to store the result of the horizontal accumulation

Member Function Documentation

◆ push()

template<class HOp , typename T , size_t SIMD_WIDTH>
void simd::HAccStore< HOp, T, SIMD_WIDTH >::push ( Vec< T, SIMD_WIDTH > v)
inline

Pushes the next Vec to be horizontally accumulated. Stores the result of the horizontal accumulation every Vec<T, SIMD_WIDTH>::elems Vec's into memory.

Parameters
vVec to be pushed