From ad739f042a6c9c71bf853c070b1dc3e38c91198d Mon Sep 17 00:00:00 2001 From: paboyle Date: Sun, 4 Mar 2018 15:56:14 +0000 Subject: [PATCH] Introduce views for passing lattice indexing to accelerators. --- lib/stencil/Stencil.h | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/lib/stencil/Stencil.h b/lib/stencil/Stencil.h index aabae99f..8debe25f 100644 --- a/lib/stencil/Stencil.h +++ b/lib/stencil/Stencil.h @@ -63,8 +63,9 @@ template void Gather_plane_simple_table (std::vector >& table,const Lattice &rhs,cobj *buffer,compressor &compress, int off,int so) { int num=table.size(); + auto rhs_v = rhs.View(); thread_loop( (int i=0;i >& table,const L assert( (table.size()&0x1)==0); int num=table.size()/2; int so = plane*rhs.Grid()->_ostride[dimension]; // base offset for start of plane + auto rhs_v = rhs.View(); thread_loop( (int j=0;j _comm_buf_size; std::vector _permute_type; Coordinate _simd_layout; - + + accelerator_inline void iCoorFromIindex(Coordinate &coor,int lane) + { + Lexicographic::CoorFromIndex(coor,lane,_simd_layout); + } + Vector _entries; // Resident in managed memory StencilEntry* _entries_p; std::vector Packets;