Small tweaks to Kokkos neighbor

This commit is contained in:
Stan Moore 2016-12-09 08:37:01 -07:00
parent 9b48c49f83
commit 435421301b
2 changed files with 4 additions and 4 deletions

View File

@ -76,7 +76,7 @@ public:
typename ArrayTypes<Device>::t_int_1d d_numneigh; // # of J neighs for each I
NeighListKokkos(class LAMMPS *lmp):
NeighList(lmp) {_stride = 1; maxneighs = 16; kokkos = 1;
NeighList(lmp) {_stride = 1; maxneighs = 16; kokkos = 1; maxatoms = 0;
execution_space = ExecutionSpaceFromDevice<Device>::space;
};
~NeighListKokkos() {numneigh = NULL; ilist = NULL;};

View File

@ -92,6 +92,9 @@ void NeighborKokkos::init_cutneighsq_kokkos(int n)
void NeighborKokkos::create_kokkos_list(int i)
{
if (style != BIN)
error->all(FLERR,"KOKKOS package only supports 'bin' neighbor lists");
if (requests[i]->kokkos_device) {
lists[i] = new NeighListKokkos<LMPDeviceType>(lmp);
device_flag = 1;
@ -227,9 +230,6 @@ void NeighborKokkos::build(int topoflag)
template<class DeviceType>
void NeighborKokkos::build_kokkos(int topoflag)
{
if (style != BIN)
error->all(FLERR,"KOKKOS package only supports 'bin' neighbor lists");
typedef DeviceType device_type;
int i,m;