16 #ifndef __IPSDKUTIL_ALIGNEDBASIC_H__ 17 #define __IPSDKUTIL_ALIGNEDBASIC_H__ 19 #include <IPSDKUtil/InstructionSet/Pack.h> 32 template <ipsdk::eInstructionSet::domain IS,
34 static IPSDK_FORCEINLINE
void 35 alignedCopy(
const BufType* pInputBuf,
39 simd::Pack<IS, BufType> inputPack;
40 for(
ipUInt64 k=0; k<size; k+=simd::NbEltsPerOp<IS>::Value) {
42 simd::load<IS>(inputPack, pInputBuf + k);
43 simd::unload<IS>(inputPack, pOutputBuf + k);
50 template <ipsdk::eInstructionSet::domain IS,
52 static IPSDK_FORCEINLINE
void 53 alignedSet(
const BufType& value,
57 simd::Pack<IS, BufType> inputPack;
58 simd::assign<IS>(inputPack, value);
59 for(
ipUInt64 k=0; k<size; k+=simd::NbEltsPerOp<IS>::Value)
60 simd::unload<IS>(inputPack, pOutputBuf + k);
68 #endif // __IPSDKUTIL_ALIGNEDBASIC_H__ Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
uint64_t ipUInt64
Base types definition.
Definition: BaseTypes.h:55
load function; loads a buffer into a pack
function assigning a given value of type T to a given Pack<instructionSet, T>
unload function; unloads a pack into a memory buffer