1
0
mirror of https://github.com/paboyle/Grid.git synced 2025-04-04 11:15:55 +01:00

Allow compress to be either vector or scalar types

This commit is contained in:
Peter Boyle 2019-05-18 17:41:13 +01:00
parent 6c4da3bbc7
commit 37336c9e0c

View File

@ -9,7 +9,7 @@ public:
void Point(int) {};
accelerator_inline int CommDatumSize(void) { return sizeof(vobj); }
accelerator_inline bool DecompressionStep(void) { return false; }
accelerator_inline void Compress(vobj *buf,int o,const vobj &in) { buf[o]=in; }
template<class cobj> accelerator_inline void Compress(cobj *buf,int o,const cobj &in) { buf[o]=in; }
accelerator_inline void Exchange(vobj *mp,vobj *vp0,vobj *vp1,Integer type,Integer o){
exchange(mp[2*o],mp[2*o+1],vp0[o],vp1[o],type);
}