}
}
- // Local state only becomes valid now.
- std::unique_ptr<t_state> stateInstance;
- t_state* state;
-
- gmx_localtop_t top(top_global.ffparams);
-
if (DOMAINDECOMP(cr))
{
- stateInstance = std::make_unique<t_state>();
- state = stateInstance.get();
+ // Local state only becomes valid now.
dd_init_local_state(*cr->dd, state_global, state);
/* Distribute the charge groups over the nodes from the master node */
state,
&f,
mdAtoms,
- &top,
+ top,
fr,
vsite,
constr,
else
{
state_change_natoms(state_global, state_global->natoms);
- /* Copy the pointer to the global state */
- state = state_global;
-
- mdAlgorithmsSetupAtomData(cr, *ir, top_global, &top, fr, &f, mdAtoms, constr, vsite, shellfc);
+ mdAlgorithmsSetupAtomData(cr, *ir, top_global, top, fr, &f, mdAtoms, constr, vsite, shellfc);
}
auto* mdatoms = mdAtoms->mdatoms();
int64_t step_rel = 0;
{
- int cglo_flags = CGLO_GSTAT;
- if (DOMAINDECOMP(cr) && dd_localTopologyChecker(*cr->dd).shouldCheckNumberOfBondedInteractions())
- {
- cglo_flags |= CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS;
- }
+ int cglo_flags = CGLO_GSTAT;
bool bSumEkinhOld = false;
t_vcm* vcm = nullptr;
compute_globals(gstat,
cglo_flags,
step,
&observablesReducer);
- if (DOMAINDECOMP(cr))
- {
- dd_localTopologyChecker(cr->dd)->checkNumberOfBondedInteractions(
- &top, makeConstArrayRef(state->x), state->box);
- }
}
if (MASTER(cr))
state,
&f,
mdAtoms,
- &top,
+ top,
fr,
vsite,
constr,
pull_work,
bNS,
force_flags,
- &top,
+ top,
constr,
enerd,
state->natoms,
step,
nrnb,
wcycle,
- &top,
+ top,
state->box,
state->x.arrayRefWithPadding(),
&state->hist,
SimulationSignaller signaller(&signals, cr, ms, doInterSimSignal, doIntraSimSignal);
int cglo_flags = CGLO_GSTAT | CGLO_ENERGY;
- if (DOMAINDECOMP(cr) && dd_localTopologyChecker(*cr->dd).shouldCheckNumberOfBondedInteractions())
- {
- cglo_flags |= CGLO_CHECK_NUMBER_OF_BONDED_INTERACTIONS;
- }
compute_globals(gstat,
cr,
ir,
cglo_flags,
step,
&observablesReducer);
- if (DOMAINDECOMP(cr))
- {
- dd_localTopologyChecker(cr->dd)->checkNumberOfBondedInteractions(
- &top, makeConstArrayRef(state->x), state->box);
- }
}
{