mirror of
https://github.com/paboyle/Grid.git
synced 2025-04-09 21:50:45 +01:00
Merge branch 'feature/dirichlet' of https://github.com/paboyle/Grid into feature/dirichlet
This commit is contained in:
commit
57bd0a0a22
@ -297,7 +297,7 @@ public:
|
|||||||
void ZeroCountersi(void) { }
|
void ZeroCountersi(void) { }
|
||||||
void Reporti(int calls) { }
|
void Reporti(int calls) { }
|
||||||
|
|
||||||
std::vector<int> surface_list;
|
// Vector<int> surface_list;
|
||||||
|
|
||||||
WilsonStencil(GridBase *grid,
|
WilsonStencil(GridBase *grid,
|
||||||
int npoints,
|
int npoints,
|
||||||
@ -307,10 +307,11 @@ public:
|
|||||||
: CartesianStencil<vobj,cobj,Parameters> (grid,npoints,checkerboard,directions,distances,p)
|
: CartesianStencil<vobj,cobj,Parameters> (grid,npoints,checkerboard,directions,distances,p)
|
||||||
{
|
{
|
||||||
ZeroCountersi();
|
ZeroCountersi();
|
||||||
surface_list.resize(0);
|
// surface_list.resize(0);
|
||||||
this->same_node.resize(npoints);
|
this->same_node.resize(npoints);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
void BuildSurfaceList(int Ls,int vol4){
|
void BuildSurfaceList(int Ls,int vol4){
|
||||||
|
|
||||||
// find same node for SHM
|
// find same node for SHM
|
||||||
@ -331,7 +332,8 @@ public:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
template < class compressor>
|
template < class compressor>
|
||||||
void HaloExchangeOpt(const Lattice<vobj> &source,compressor &compress)
|
void HaloExchangeOpt(const Lattice<vobj> &source,compressor &compress)
|
||||||
{
|
{
|
||||||
|
@ -440,6 +440,17 @@ void WilsonKernels<Impl>::DhopDirKernel( StencilImpl &st, DoubledGaugeField &U,S
|
|||||||
|
|
||||||
#define KERNEL_CALL(A) KERNEL_CALLNB(A); accelerator_barrier();
|
#define KERNEL_CALL(A) KERNEL_CALLNB(A); accelerator_barrier();
|
||||||
|
|
||||||
|
#define KERNEL_CALL_EXT(A) \
|
||||||
|
const uint64_t NN = Nsite*Ls; \
|
||||||
|
const uint64_t sz = st.surface_list.size(); \
|
||||||
|
auto ptr = &st.surface_list[0]; \
|
||||||
|
accelerator_forNB( ss, sz, Simd::Nsimd(), { \
|
||||||
|
int sF = ptr[ss]; \
|
||||||
|
int sU = ss/Ls; \
|
||||||
|
WilsonKernels<Impl>::A(st_v,U_v,buf,sF,sU,in_v,out_v); \
|
||||||
|
}); \
|
||||||
|
accelerator_barrier();
|
||||||
|
|
||||||
#define ASM_CALL(A) \
|
#define ASM_CALL(A) \
|
||||||
thread_for( ss, Nsite, { \
|
thread_for( ss, Nsite, { \
|
||||||
int sU = ss; \
|
int sU = ss; \
|
||||||
|
@ -640,7 +640,9 @@ public:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(local == 0) {
|
if(local == 0) {
|
||||||
surface_list.push_back(site);
|
for(int s=0;s<Ls;s++){
|
||||||
|
surface_list.push_back(site*Ls+s);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user