From 4e88cd158ee21fc4fcdfc85d66073ea5b220f6bc Mon Sep 17 00:00:00 2001 From: Trung Nguyen Date: Mon, 20 Sep 2021 11:38:50 -0500 Subject: [PATCH] Fixed bugs with _tep and _fieldp to allow mixed-precision builds, being defensive with acctyp for these variables --- lib/gpu/lal_amoeba.cu | 140 ++++++++++++++++++------------------- lib/gpu/lal_amoeba_ext.cpp | 2 +- lib/gpu/lal_base_amoeba.h | 2 +- 3 files changed, 72 insertions(+), 72 deletions(-) diff --git a/lib/gpu/lal_amoeba.cu b/lib/gpu/lal_amoeba.cu index 8915ef0146..3c5b949c72 100644 --- a/lib/gpu/lal_amoeba.cu +++ b/lib/gpu/lal_amoeba.cu @@ -102,7 +102,7 @@ _texture( q_tex,int2); dufld[5]=red_acc[5][tid]; \ } \ if (offset==0 && ii> SBBITS & 3; - int j = sj & NEIGHMASK; - tagint jtag = tag[j]; - - if (!which) { - int offset=ii; - for (int k=0; k> SBBITS & 3; + int j = sj & NEIGHMASK; + tagint jtag = tag[j]; + + if (!which) { + int offset=ii; + for (int k=0; kgpu_rank(); int procs_per_gpu=AMOEBAMF.device->procs_per_gpu(); - tep_size=sizeof(PRECISION); + tep_size=sizeof(ACC_PRECISION); // tep_size=sizeof(PRECISION); AMOEBAMF.device->init_message(screen,"amoeba",first_gpu,last_gpu); diff --git a/lib/gpu/lal_base_amoeba.h b/lib/gpu/lal_base_amoeba.h index a45316b6f3..fea1728e8c 100644 --- a/lib/gpu/lal_base_amoeba.h +++ b/lib/gpu/lal_base_amoeba.h @@ -235,7 +235,7 @@ class BaseAmoeba { double** uind, double** uinp); /// Per-atom arrays - UCL_Vector _tep, _fieldp; + UCL_Vector _tep, _fieldp; int _nmax, _max_tep_size, _max_fieldp_size; // ------------------------ FORCE/ENERGY DATA -----------------------