git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@12368 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
@ -42,6 +42,10 @@ Angle::Angle(LAMMPS *lmp) : Pointers(lmp)
|
|||||||
|
|
||||||
datamask = ALL_MASK;
|
datamask = ALL_MASK;
|
||||||
datamask_ext = ALL_MASK;
|
datamask_ext = ALL_MASK;
|
||||||
|
|
||||||
|
execution_space = Host;
|
||||||
|
datamask_read = ALL_MASK;
|
||||||
|
datamask_modify = ALL_MASK;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|||||||
@ -32,6 +32,10 @@ class Angle : protected Pointers {
|
|||||||
unsigned int datamask;
|
unsigned int datamask;
|
||||||
unsigned int datamask_ext;
|
unsigned int datamask_ext;
|
||||||
|
|
||||||
|
// KOKKOS host/device flag and data masks
|
||||||
|
ExecutionSpace execution_space;
|
||||||
|
unsigned int datamask_read,datamask_modify;
|
||||||
|
|
||||||
Angle(class LAMMPS *);
|
Angle(class LAMMPS *);
|
||||||
virtual ~Angle();
|
virtual ~Angle();
|
||||||
virtual void init();
|
virtual void init();
|
||||||
|
|||||||
@ -43,6 +43,10 @@ Bond::Bond(LAMMPS *lmp) : Pointers(lmp)
|
|||||||
|
|
||||||
datamask = ALL_MASK;
|
datamask = ALL_MASK;
|
||||||
datamask_ext = ALL_MASK;
|
datamask_ext = ALL_MASK;
|
||||||
|
|
||||||
|
execution_space = Host;
|
||||||
|
datamask_read = ALL_MASK;
|
||||||
|
datamask_modify = ALL_MASK;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|||||||
@ -32,6 +32,10 @@ class Bond : protected Pointers {
|
|||||||
unsigned int datamask;
|
unsigned int datamask;
|
||||||
unsigned int datamask_ext;
|
unsigned int datamask_ext;
|
||||||
|
|
||||||
|
// KOKKOS host/device flag and data masks
|
||||||
|
ExecutionSpace execution_space;
|
||||||
|
unsigned int datamask_read,datamask_modify;
|
||||||
|
|
||||||
Bond(class LAMMPS *);
|
Bond(class LAMMPS *);
|
||||||
virtual ~Bond();
|
virtual ~Bond();
|
||||||
virtual void init();
|
virtual void init();
|
||||||
|
|||||||
@ -43,6 +43,10 @@ Dihedral::Dihedral(LAMMPS *lmp) : Pointers(lmp)
|
|||||||
|
|
||||||
datamask = ALL_MASK;
|
datamask = ALL_MASK;
|
||||||
datamask_ext = ALL_MASK;
|
datamask_ext = ALL_MASK;
|
||||||
|
|
||||||
|
execution_space = Host;
|
||||||
|
datamask_read = ALL_MASK;
|
||||||
|
datamask_modify = ALL_MASK;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|||||||
@ -32,6 +32,10 @@ class Dihedral : protected Pointers {
|
|||||||
unsigned int datamask;
|
unsigned int datamask;
|
||||||
unsigned int datamask_ext;
|
unsigned int datamask_ext;
|
||||||
|
|
||||||
|
// KOKKOS host/device flag and data masks
|
||||||
|
ExecutionSpace execution_space;
|
||||||
|
unsigned int datamask_read,datamask_modify;
|
||||||
|
|
||||||
Dihedral(class LAMMPS *);
|
Dihedral(class LAMMPS *);
|
||||||
virtual ~Dihedral();
|
virtual ~Dihedral();
|
||||||
virtual void init();
|
virtual void init();
|
||||||
|
|||||||
@ -73,7 +73,7 @@ FixLangevin::FixLangevin(LAMMPS *lmp, int narg, char **arg) :
|
|||||||
|
|
||||||
t_stop = force->numeric(FLERR,arg[4]);
|
t_stop = force->numeric(FLERR,arg[4]);
|
||||||
t_period = force->numeric(FLERR,arg[5]);
|
t_period = force->numeric(FLERR,arg[5]);
|
||||||
int seed = force->inumeric(FLERR,arg[6]);
|
seed = force->inumeric(FLERR,arg[6]);
|
||||||
|
|
||||||
if (t_period <= 0.0) error->all(FLERR,"Fix langevin period must be > 0.0");
|
if (t_period <= 0.0) error->all(FLERR,"Fix langevin period must be > 0.0");
|
||||||
if (seed <= 0) error->all(FLERR,"Illegal fix langevin command");
|
if (seed <= 0) error->all(FLERR,"Illegal fix langevin command");
|
||||||
|
|||||||
@ -69,6 +69,7 @@ class FixLangevin : public Fix {
|
|||||||
|
|
||||||
int nlevels_respa;
|
int nlevels_respa;
|
||||||
class RanMars *random;
|
class RanMars *random;
|
||||||
|
int seed;
|
||||||
|
|
||||||
// comment next line to turn off templating
|
// comment next line to turn off templating
|
||||||
#define TEMPLATED_FIX_LANGEVIN
|
#define TEMPLATED_FIX_LANGEVIN
|
||||||
|
|||||||
@ -40,6 +40,10 @@ Improper::Improper(LAMMPS *lmp) : Pointers(lmp)
|
|||||||
|
|
||||||
datamask = ALL_MASK;
|
datamask = ALL_MASK;
|
||||||
datamask_ext = ALL_MASK;
|
datamask_ext = ALL_MASK;
|
||||||
|
|
||||||
|
execution_space = Host;
|
||||||
|
datamask_read = ALL_MASK;
|
||||||
|
datamask_modify = ALL_MASK;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|||||||
@ -32,6 +32,10 @@ class Improper : protected Pointers {
|
|||||||
unsigned int datamask;
|
unsigned int datamask;
|
||||||
unsigned int datamask_ext;
|
unsigned int datamask_ext;
|
||||||
|
|
||||||
|
// KOKKOS host/device flag and data masks
|
||||||
|
ExecutionSpace execution_space;
|
||||||
|
unsigned int datamask_read,datamask_modify;
|
||||||
|
|
||||||
Improper(class LAMMPS *);
|
Improper(class LAMMPS *);
|
||||||
virtual ~Improper();
|
virtual ~Improper();
|
||||||
virtual void init();
|
virtual void init();
|
||||||
|
|||||||
@ -88,6 +88,10 @@ KSpace::KSpace(LAMMPS *lmp, int narg, char **arg) : Pointers(lmp)
|
|||||||
datamask = ALL_MASK;
|
datamask = ALL_MASK;
|
||||||
datamask_ext = ALL_MASK;
|
datamask_ext = ALL_MASK;
|
||||||
|
|
||||||
|
execution_space = Host;
|
||||||
|
datamask_read = ALL_MASK;
|
||||||
|
datamask_modify = ALL_MASK;
|
||||||
|
|
||||||
memory->create(gcons,7,7,"kspace:gcons");
|
memory->create(gcons,7,7,"kspace:gcons");
|
||||||
gcons[2][0] = 15.0 / 8.0;
|
gcons[2][0] = 15.0 / 8.0;
|
||||||
gcons[2][1] = -5.0 / 4.0;
|
gcons[2][1] = -5.0 / 4.0;
|
||||||
|
|||||||
@ -76,6 +76,10 @@ class KSpace : protected Pointers {
|
|||||||
unsigned int datamask;
|
unsigned int datamask;
|
||||||
unsigned int datamask_ext;
|
unsigned int datamask_ext;
|
||||||
|
|
||||||
|
// KOKKOS host/device flag and data masks
|
||||||
|
ExecutionSpace execution_space;
|
||||||
|
unsigned int datamask_read,datamask_modify;
|
||||||
|
|
||||||
int compute_flag; // 0 if skip compute()
|
int compute_flag; // 0 if skip compute()
|
||||||
int fftbench; // 0 if skip FFT timing
|
int fftbench; // 0 if skip FFT timing
|
||||||
int collective_flag; // 1 if use MPI collectives for FFT/remap
|
int collective_flag; // 1 if use MPI collectives for FFT/remap
|
||||||
|
|||||||
@ -568,6 +568,7 @@ class Memory : protected Pointers {
|
|||||||
template <typename TYPE>
|
template <typename TYPE>
|
||||||
bigint usage(TYPE *array, int n)
|
bigint usage(TYPE *array, int n)
|
||||||
{
|
{
|
||||||
|
(void) array;
|
||||||
bigint bytes = ((bigint) sizeof(TYPE)) * n;
|
bigint bytes = ((bigint) sizeof(TYPE)) * n;
|
||||||
return bytes;
|
return bytes;
|
||||||
}
|
}
|
||||||
@ -575,6 +576,7 @@ class Memory : protected Pointers {
|
|||||||
template <typename TYPE>
|
template <typename TYPE>
|
||||||
bigint usage(TYPE **array, int n1, int n2)
|
bigint usage(TYPE **array, int n1, int n2)
|
||||||
{
|
{
|
||||||
|
(void) array;
|
||||||
bigint bytes = ((bigint) sizeof(TYPE)) * n1*n2;
|
bigint bytes = ((bigint) sizeof(TYPE)) * n1*n2;
|
||||||
bytes += ((bigint) sizeof(TYPE *)) * n1;
|
bytes += ((bigint) sizeof(TYPE *)) * n1;
|
||||||
return bytes;
|
return bytes;
|
||||||
@ -583,6 +585,7 @@ class Memory : protected Pointers {
|
|||||||
template <typename TYPE>
|
template <typename TYPE>
|
||||||
bigint usage(TYPE ***array, int n1, int n2, int n3)
|
bigint usage(TYPE ***array, int n1, int n2, int n3)
|
||||||
{
|
{
|
||||||
|
(void) array;
|
||||||
bigint bytes = ((bigint) sizeof(TYPE)) * n1*n2*n3;
|
bigint bytes = ((bigint) sizeof(TYPE)) * n1*n2*n3;
|
||||||
bytes += ((bigint) sizeof(TYPE *)) * n1*n2;
|
bytes += ((bigint) sizeof(TYPE *)) * n1*n2;
|
||||||
bytes += ((bigint) sizeof(TYPE **)) * n1;
|
bytes += ((bigint) sizeof(TYPE **)) * n1;
|
||||||
@ -592,6 +595,7 @@ class Memory : protected Pointers {
|
|||||||
template <typename TYPE>
|
template <typename TYPE>
|
||||||
bigint usage(TYPE ****array, int n1, int n2, int n3, int n4)
|
bigint usage(TYPE ****array, int n1, int n2, int n3, int n4)
|
||||||
{
|
{
|
||||||
|
(void) array;
|
||||||
bigint bytes = ((bigint) sizeof(TYPE)) * n1*n2*n3*n4;
|
bigint bytes = ((bigint) sizeof(TYPE)) * n1*n2*n3*n4;
|
||||||
bytes += ((bigint) sizeof(TYPE *)) * n1*n2*n3;
|
bytes += ((bigint) sizeof(TYPE *)) * n1*n2*n3;
|
||||||
bytes += ((bigint) sizeof(TYPE **)) * n1*n2;
|
bytes += ((bigint) sizeof(TYPE **)) * n1*n2;
|
||||||
|
|||||||
Reference in New Issue
Block a user