You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Get index of first TD
int ix = blockIdx.xblockDim.xNUM_TD_PER_THREAD + threadIdx.x;
// Have extra threads do the last member intead of return.
// A return would disable use of barriers, so not using return is better
ix = ix < numTransforms ? ix : numTransforms - NUM_TD_PER_THREAD;
For the CUDA example
// Get index of first TD
int ix = blockIdx.xblockDim.xNUM_TD_PER_THREAD + threadIdx.x;
// Have extra threads do the last member intead of return.
// A return would disable use of barriers, so not using return is better
ix = ix < numTransforms ? ix : numTransforms - NUM_TD_PER_THREAD;
#ifdef USE_SHARED
extern shared FFParams forcefield[];
if(ix < num_atom_types)
{
forcefield[ix] = global_forcefield[ix];
}
#else
I think the ix in the shared case should be threadIdx.x. should't be ?
The text was updated successfully, but these errors were encountered: