git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@15247 f3b2605a-c512-4ea7-a41b-209d697bcdaa

This commit is contained in:
sjplimp 2016-07-01 23:25:50 +00:00
parent cedb420ebc
commit 8366b35459
10 changed files with 37 additions and 37 deletions

View File

@ -132,7 +132,7 @@ if (test $1 = 1) then
if (test -e ../Makefile.package) then
sed -i -e 's/[^ \t]*gpu[^ \t]* //' ../Makefile.package
sed -i -e 's|^PKG_PATH =[ \t]*|&-L../../lib/gpu |' ../Makefile.package
sed -i -e 's|^PKG_PATH =[ \t]*|&-L../../lib/gpu$(LIBOBJDIR) |' ../Makefile.package
sed -i -e 's|^PKG_LIB =[ \t]*|&-lgpu |' ../Makefile.package
sed -i -e 's|^PKG_SYSINC =[ \t]*|&$(gpu_SYSINC) |' ../Makefile.package
sed -i -e 's|^PKG_SYSLIB =[ \t]*|&$(gpu_SYSLIB) |' ../Makefile.package

View File

@ -182,8 +182,8 @@ void PairBornCoulLongGPU::init_style()
int success = borncl_gpu_init(atom->ntypes+1, cutsq, rhoinv,
born1, born2, born3, a, c, d, sigma,
offset, force->special_lj, atom->nlocal,
atom->nlocal+atom->nghost, 300, maxspecial,
cell_size, gpu_mode, screen, cut_ljsq,
atom->nlocal+atom->nghost, 300, maxspecial,
cell_size, gpu_mode, screen, cut_ljsq,
cut_coulsq, force->special_coul,
force->qqrd2e, g_ewald);

View File

@ -71,7 +71,7 @@ double borncw_gpu_bytes();
/* ---------------------------------------------------------------------- */
PairBornCoulWolfGPU::PairBornCoulWolfGPU(LAMMPS *lmp) : PairBornCoulWolf(lmp),
gpu_mode(GPU_FORCE)
gpu_mode(GPU_FORCE)
{
respa_enable = 0;
reinitflag = 0;

View File

@ -155,7 +155,7 @@ void PairBornGPU::init_style()
born1, born2, born3, a, c, d, sigma,
offset, force->special_lj, atom->nlocal,
atom->nlocal+atom->nghost, 300, maxspecial,
cell_size, gpu_mode, screen);
cell_size, gpu_mode, screen);
GPU_EXTRA::check_flag(success,error,world);
if (gpu_mode == GPU_FORCE) {

View File

@ -153,7 +153,7 @@ void PairLJGromacsGPU::init_style()
maxspecial=atom->maxspecial;
int success = ljgrm_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4,
force->special_lj, atom->nlocal,
force->special_lj, atom->nlocal,
atom->nlocal+atom->nghost, 300, maxspecial,
cell_size, gpu_mode, screen, ljsw1, ljsw2,
ljsw3, ljsw4, ljsw5, cut_inner, cut_inner_sq);
@ -215,31 +215,31 @@ void PairLJGromacsGPU::cpu_compute(int start, int inum, int eflag,
if (rsq < cutsq[itype][jtype]) {
r2inv = 1.0/rsq;
r6inv = r2inv*r2inv*r2inv;
r6inv = r2inv*r2inv*r2inv;
forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]);
if (rsq > cut_inner_sq[itype][jtype]) {
if (rsq > cut_inner_sq[itype][jtype]) {
r = sqrt(rsq);
t = r - cut_inner[itype][jtype];
fswitch = r*t*t*(ljsw1[itype][jtype] + ljsw2[itype][jtype]*t);
forcelj += fswitch;
fswitch = r*t*t*(ljsw1[itype][jtype] + ljsw2[itype][jtype]*t);
forcelj += fswitch;
}
fpair = factor_lj*forcelj * r2inv;
fpair = factor_lj*forcelj * r2inv;
f[i][0] += delx*fpair;
f[i][1] += dely*fpair;
f[i][2] += delz*fpair;
f[i][0] += delx*fpair;
f[i][1] += dely*fpair;
f[i][2] += delz*fpair;
if (eflag) {
evdwl = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]);
evdwl += ljsw5[itype][jtype];
if (eflag) {
evdwl = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]);
evdwl += ljsw5[itype][jtype];
if (rsq > cut_inner_sq[itype][jtype]) {
eswitch = t*t*t*(ljsw3[itype][jtype] + ljsw4[itype][jtype]*t);
evdwl += eswitch;
}
evdwl *= factor_lj;
}
evdwl *= factor_lj;
}
if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz);
if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz);
}
}
}

View File

@ -115,7 +115,7 @@ void PairSWGPU::compute(int eflag, int vflag)
numneigh = list->numneigh;
firstneigh = list->firstneigh;
sw_gpu_compute(neighbor->ago, atom->nlocal, nall, inum+list->gnum,
sw_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum,
atom->x, atom->type, ilist, numneigh, firstneigh, eflag,
vflag, eflag_atom, vflag_atom, host_start, cpu_time,
success);

View File

@ -119,7 +119,7 @@ void PairTersoffGPU::compute(int eflag, int vflag)
numneigh = list->numneigh;
firstneigh = list->firstneigh;
tersoff_gpu_compute(neighbor->ago, atom->nlocal, nall, inum+list->gnum,
tersoff_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum,
atom->x, atom->type, ilist, numneigh, firstneigh, eflag,
vflag, eflag_atom, vflag_atom, host_start, cpu_time,
success);

View File

@ -112,7 +112,7 @@ void PairTersoffMODGPU::compute(int eflag, int vflag)
numneigh = list->numneigh;
firstneigh = list->firstneigh;
tersoff_mod_gpu_compute(neighbor->ago, atom->nlocal, nall, inum+list->gnum,
tersoff_mod_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum,
atom->x, atom->type, ilist, numneigh, firstneigh, eflag,
vflag, eflag_atom, vflag_atom, host_start, cpu_time,
success);

View File

@ -120,7 +120,7 @@ void PairTersoffZBLGPU::compute(int eflag, int vflag)
numneigh = list->numneigh;
firstneigh = list->firstneigh;
tersoff_zbl_gpu_compute(neighbor->ago, atom->nlocal, nall, inum+list->gnum,
tersoff_zbl_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum,
atom->x, atom->type, ilist, numneigh, firstneigh, eflag,
vflag, eflag_atom, vflag_atom, host_start, cpu_time,
success);

View File

@ -210,15 +210,15 @@ void PairZBLGPU::cpu_compute(int start, int inum, int eflag, int vflag,
jtype = type[j];
if (rsq < cut_globalsq) {
r = sqrt(rsq);
r = sqrt(rsq);
fpair = dzbldr(r, itype, jtype);
if (rsq > cut_innersq) {
t = r - cut_inner;
fswitch = t*t *
(sw1[itype][jtype] + sw2[itype][jtype]*t);
fpair += fswitch;
}
if (rsq > cut_innersq) {
t = r - cut_inner;
fswitch = t*t *
(sw1[itype][jtype] + sw2[itype][jtype]*t);
fpair += fswitch;
}
fpair *= -1.0/r;
f[i][0] += delx*fpair;
@ -227,12 +227,12 @@ void PairZBLGPU::cpu_compute(int start, int inum, int eflag, int vflag,
if (eflag) {
evdwl = e_zbl(r, itype, jtype);
evdwl += sw5[itype][jtype];
if (rsq > cut_innersq) {
eswitch = t*t*t *
(sw3[itype][jtype] + sw4[itype][jtype]*t);
evdwl += eswitch;
}
evdwl += sw5[itype][jtype];
if (rsq > cut_innersq) {
eswitch = t*t*t *
(sw3[itype][jtype] + sw4[itype][jtype]*t);
evdwl += eswitch;
}
}
if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz);