The total dipole reduction happens in do_force() and the alternative
code-path reduction in compute_globals() was only needed for log
reporting which was removed some time ago.
Change-Id: I49a2608e8c1a47959a5f0f571e38e511367c94b2
tensor shake_vir,
tensor total_vir,
tensor pres,
tensor shake_vir,
tensor total_vir,
tensor pres,
gmx::Constraints* constr,
gmx::SimulationSignaller* signalCoordinator,
const matrix lastbox,
gmx::Constraints* constr,
gmx::SimulationSignaller* signalCoordinator,
const matrix lastbox,
if (PAR(cr))
{
wallcycle_start(wcycle, ewcMoveE);
if (PAR(cr))
{
wallcycle_start(wcycle, ewcMoveE);
- global_stat(gstat, cr, enerd, force_vir, shake_vir, mu_tot, ir, ekind, constr,
+ global_stat(gstat, cr, enerd, force_vir, shake_vir, ir, ekind, constr,
bStopCM ? vcm : nullptr, signalBuffer.size(), signalBuffer.data(),
totalNumberOfBondedInteractions, *bSumEkinhOld, flags);
wallcycle_stop(wcycle, ewcMoveE);
bStopCM ? vcm : nullptr, signalBuffer.size(), signalBuffer.data(),
totalNumberOfBondedInteractions, *bSumEkinhOld, flags);
wallcycle_stop(wcycle, ewcMoveE);
tensor shake_vir,
tensor total_vir,
tensor pres,
tensor shake_vir,
tensor total_vir,
tensor pres,
gmx::Constraints* constr,
gmx::SimulationSignaller* signalCoordinator,
const matrix lastbox,
gmx::Constraints* constr,
gmx::SimulationSignaller* signalCoordinator,
const matrix lastbox,
gmx_enerdata_t* enerd,
tensor fvir,
tensor svir,
gmx_enerdata_t* enerd,
tensor fvir,
tensor svir,
const t_inputrec* inputrec,
gmx_ekindata_t* ekind,
const gmx::Constraints* constr,
const t_inputrec* inputrec,
gmx_ekindata_t* ekind,
const gmx::Constraints* constr,
{
t_bin* rb;
int * itc0, *itc1;
{
t_bin* rb;
int * itc0, *itc1;
- int ie = 0, ifv = 0, isv = 0, irmsd = 0, imu = 0;
+ int ie = 0, ifv = 0, isv = 0, irmsd = 0;
int idedl = 0, idedlo = 0, idvdll = 0, idvdlnl = 0, iepl = 0, icm = 0, imass = 0, ica = 0, inb = 0;
int isig = -1;
int icj = -1, ici = -1, icx = -1;
int idedl = 0, idedlo = 0, idvdll = 0, idvdlnl = 0, iepl = 0, icm = 0, imass = 0, ica = 0, inb = 0;
int isig = -1;
int icj = -1, ici = -1, icx = -1;
irmsd = add_binr(rb, 2, rmsdData.data());
}
}
irmsd = add_binr(rb, 2, rmsdData.data());
}
}
- if (!inputrecNeedMutot(inputrec))
- {
- imu = add_binr(rb, DIM, mu_tot);
- }
for (j = 0; (j < egNR); j++)
{
for (j = 0; (j < egNR); j++)
{
{
extract_binr(rb, irmsd, rmsdData);
}
{
extract_binr(rb, irmsd, rmsdData);
}
- if (!inputrecNeedMutot(inputrec))
- {
- extract_binr(rb, imu, DIM, mu_tot);
- }
for (j = 0; (j < egNR); j++)
{
for (j = 0; (j < egNR); j++)
{
gmx_enerdata_t* enerd,
tensor fvir,
tensor svir,
gmx_enerdata_t* enerd,
tensor fvir,
tensor svir,
const t_inputrec* inputrec,
gmx_ekindata_t* ekind,
const gmx::Constraints* constr,
const t_inputrec* inputrec,
gmx_ekindata_t* ekind,
const gmx::Constraints* constr,
}
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, nullptr, enerd,
}
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, nullptr, enerd,
- force_vir, shake_vir, total_vir, pres, mu_tot, constr, &nullSignaller,
- state->box, &totalNumberOfBondedInteractions, &bSumEkinhOld,
+ force_vir, shake_vir, total_vir, pres, constr, &nullSignaller, state->box,
+ &totalNumberOfBondedInteractions, &bSumEkinhOld,
cglo_flags_iteration
| (shouldCheckNumberOfBondedInteractions ? CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS
: 0));
cglo_flags_iteration
| (shouldCheckNumberOfBondedInteractions ? CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS
: 0));
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, nullptr, enerd,
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, nullptr, enerd,
- force_vir, shake_vir, total_vir, pres, mu_tot, constr, &nullSignaller,
- state->box, nullptr, &bSumEkinhOld, cglo_flags & ~CGLO_PRESSURE);
+ force_vir, shake_vir, total_vir, pres, constr, &nullSignaller, state->box,
+ nullptr, &bSumEkinhOld, cglo_flags & ~CGLO_PRESSURE);
}
/* Calculate the initial half step temperature, and save the ekinh_old */
}
/* Calculate the initial half step temperature, and save the ekinh_old */
/* This may not be quite working correctly yet . . . . */
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, wcycle, enerd,
/* This may not be quite working correctly yet . . . . */
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, wcycle, enerd,
- nullptr, nullptr, nullptr, nullptr, mu_tot, constr, &nullSignaller,
- state->box, &totalNumberOfBondedInteractions, &bSumEkinhOld,
+ nullptr, nullptr, nullptr, nullptr, constr, &nullSignaller, state->box,
+ &totalNumberOfBondedInteractions, &bSumEkinhOld,
CGLO_GSTAT | CGLO_TEMPERATURE | CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS);
checkNumberOfBondedInteractions(mdlog, cr, totalNumberOfBondedInteractions, top_global,
&top, state->x.rvec_array(), state->box,
CGLO_GSTAT | CGLO_TEMPERATURE | CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS);
checkNumberOfBondedInteractions(mdlog, cr, totalNumberOfBondedInteractions, top_global,
&top, state->x.rvec_array(), state->box,
{
wallcycle_stop(wcycle, ewcUPDATE);
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
{
wallcycle_stop(wcycle, ewcUPDATE);
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
- state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, wcycle, enerd,
- force_vir, shake_vir, total_vir, pres, mu_tot, constr, &nullSignaller,
+ state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, wcycle,
+ enerd, force_vir, shake_vir, total_vir, pres, constr, &nullSignaller,
state->box, &totalNumberOfBondedInteractions, &bSumEkinhOld,
(bGStat ? CGLO_GSTAT : 0) | (bCalcEner ? CGLO_ENERGY : 0)
| (bTemp ? CGLO_TEMPERATURE : 0) | (bPres ? CGLO_PRESSURE : 0)
state->box, &totalNumberOfBondedInteractions, &bSumEkinhOld,
(bGStat ? CGLO_GSTAT : 0) | (bCalcEner ? CGLO_ENERGY : 0)
| (bTemp ? CGLO_TEMPERATURE : 0) | (bPres ? CGLO_PRESSURE : 0)
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(),
state->v.rvec_array(), state->box, state->lambda[efptVDW],
mdatoms, nrnb, &vcm, wcycle, enerd, nullptr, nullptr, nullptr,
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(),
state->v.rvec_array(), state->box, state->lambda[efptVDW],
mdatoms, nrnb, &vcm, wcycle, enerd, nullptr, nullptr, nullptr,
- nullptr, mu_tot, constr, &nullSignaller, state->box, nullptr,
+ nullptr, constr, &nullSignaller, state->box, nullptr,
&bSumEkinhOld, CGLO_GSTAT | CGLO_TEMPERATURE);
wallcycle_start(wcycle, ewcUPDATE);
}
&bSumEkinhOld, CGLO_GSTAT | CGLO_TEMPERATURE);
wallcycle_start(wcycle, ewcUPDATE);
}
/* just compute the kinetic energy at the half step to perform a trotter step */
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, wcycle, enerd,
/* just compute the kinetic energy at the half step to perform a trotter step */
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, wcycle, enerd,
- force_vir, shake_vir, total_vir, pres, mu_tot, constr, &nullSignaller, lastbox,
+ force_vir, shake_vir, total_vir, pres, constr, &nullSignaller, lastbox,
nullptr, &bSumEkinhOld, (bGStat ? CGLO_GSTAT : 0) | CGLO_TEMPERATURE);
wallcycle_start(wcycle, ewcUPDATE);
trotter_update(ir, step, ekind, enerd, state, total_vir, mdatoms, &MassQ, trotter_seq, ettTSEQ4);
nullptr, &bSumEkinhOld, (bGStat ? CGLO_GSTAT : 0) | CGLO_TEMPERATURE);
wallcycle_start(wcycle, ewcUPDATE);
trotter_update(ir, step, ekind, enerd, state, total_vir, mdatoms, &MassQ, trotter_seq, ettTSEQ4);
compute_globals(
gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, wcycle, enerd,
compute_globals(
gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, &vcm, wcycle, enerd,
- force_vir, shake_vir, total_vir, pres, mu_tot, constr, &signaller, lastbox,
+ force_vir, shake_vir, total_vir, pres, constr, &signaller, lastbox,
&totalNumberOfBondedInteractions, &bSumEkinhOld,
(bGStat ? CGLO_GSTAT : 0) | (!EI_VV(ir->eI) && bCalcEner ? CGLO_ENERGY : 0)
| (!EI_VV(ir->eI) && bStopCM ? CGLO_STOPCM : 0)
&totalNumberOfBondedInteractions, &bSumEkinhOld,
(bGStat ? CGLO_GSTAT : 0) | (!EI_VV(ir->eI) && bCalcEner ? CGLO_ENERGY : 0)
| (!EI_VV(ir->eI) && bStopCM ? CGLO_STOPCM : 0)
t_vcm* vcm = nullptr;
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, vcm, nullptr, enerd,
t_vcm* vcm = nullptr;
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, vcm, nullptr, enerd,
- force_vir, shake_vir, total_vir, pres, mu_tot, constr, &nullSignaller,
- state->box, &totalNumberOfBondedInteractions, &bSumEkinhOld, cglo_flags);
+ force_vir, shake_vir, total_vir, pres, constr, &nullSignaller, state->box,
+ &totalNumberOfBondedInteractions, &bSumEkinhOld, cglo_flags);
}
checkNumberOfBondedInteractions(mdlog, cr, totalNumberOfBondedInteractions, top_global, &top,
state->x.rvec_array(), state->box,
}
checkNumberOfBondedInteractions(mdlog, cr, totalNumberOfBondedInteractions, top_global, &top,
state->x.rvec_array(), state->box,
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, vcm, wcycle, enerd,
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, vcm, wcycle, enerd,
- nullptr, nullptr, nullptr, nullptr, mu_tot, constr, &signaller,
- state->box, &totalNumberOfBondedInteractions, &bSumEkinhOld,
+ nullptr, nullptr, nullptr, nullptr, constr, &signaller, state->box,
+ &totalNumberOfBondedInteractions, &bSumEkinhOld,
CGLO_GSTAT | CGLO_ENERGY
| (shouldCheckNumberOfBondedInteractions ? CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS
: 0));
CGLO_GSTAT | CGLO_ENERGY
| (shouldCheckNumberOfBondedInteractions ? CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS
: 0));
{
wallcycle_start(wcycle, ewcMoveE);
{
wallcycle_start(wcycle, ewcMoveE);
- global_stat(gstat, cr, enerd, force_vir, shake_vir, mu_tot, inputrec, nullptr, nullptr, nullptr,
- 1, &terminate, nullptr, FALSE, CGLO_ENERGY | CGLO_PRESSURE | CGLO_CONSTRAINT);
+ global_stat(gstat, cr, enerd, force_vir, shake_vir, inputrec, nullptr, nullptr, nullptr, 1,
+ &terminate, nullptr, FALSE, CGLO_ENERGY | CGLO_PRESSURE | CGLO_CONSTRAINT);
wallcycle_stop(wcycle, ewcMoveE);
}
wallcycle_stop(wcycle, ewcMoveE);
}
t_vcm* vcm = nullptr;
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, vcm, nullptr, enerd,
t_vcm* vcm = nullptr;
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, vcm, nullptr, enerd,
- force_vir, shake_vir, total_vir, pres, mu_tot, constr, &nullSignaller,
- state->box, &totalNumberOfBondedInteractions, &bSumEkinhOld, cglo_flags);
+ force_vir, shake_vir, total_vir, pres, constr, &nullSignaller, state->box,
+ &totalNumberOfBondedInteractions, &bSumEkinhOld, cglo_flags);
}
checkNumberOfBondedInteractions(mdlog, cr, totalNumberOfBondedInteractions, top_global, &top,
state->x.rvec_array(), state->box,
}
checkNumberOfBondedInteractions(mdlog, cr, totalNumberOfBondedInteractions, top_global, &top,
state->x.rvec_array(), state->box,
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, vcm, wcycle, enerd,
compute_globals(gstat, cr, ir, fr, ekind, state->x.rvec_array(), state->v.rvec_array(),
state->box, state->lambda[efptVDW], mdatoms, nrnb, vcm, wcycle, enerd,
- force_vir, shake_vir, total_vir, pres, mu_tot, constr, &signaller,
- state->box, &totalNumberOfBondedInteractions, &bSumEkinhOld,
+ force_vir, shake_vir, total_vir, pres, constr, &signaller, state->box,
+ &totalNumberOfBondedInteractions, &bSumEkinhOld,
CGLO_GSTAT | CGLO_ENERGY
| (shouldCheckNumberOfBondedInteractions ? CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS
: 0));
CGLO_GSTAT | CGLO_ENERGY
| (shouldCheckNumberOfBondedInteractions ? CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS
: 0));
mdAtoms_->mdatoms(), nrnb_, &vcm_, step != -1 ? wcycle_ : nullptr,
energyElement_->enerdata(), energyElement_->forceVirial(step),
energyElement_->constraintVirial(step), energyElement_->totalVirial(step),
mdAtoms_->mdatoms(), nrnb_, &vcm_, step != -1 ? wcycle_ : nullptr,
energyElement_->enerdata(), energyElement_->forceVirial(step),
energyElement_->constraintVirial(step), energyElement_->totalVirial(step),
- energyElement_->pressure(step), energyElement_->muTot(), constr_, signaller, lastbox,
+ energyElement_->pressure(step), constr_, signaller, lastbox,
&totalNumberOfBondedInteractions_, energyElement_->needToSumEkinhOld(), flags);
checkNumberOfBondedInteractions(mdlog_, cr_, totalNumberOfBondedInteractions_, top_global_,
localTopology_, x, box, &shouldCheckNumberOfBondedInteractions_);
&totalNumberOfBondedInteractions_, energyElement_->needToSumEkinhOld(), flags);
checkNumberOfBondedInteractions(mdlog_, cr_, totalNumberOfBondedInteractions_, top_global_,
localTopology_, x, box, &shouldCheckNumberOfBondedInteractions_);