t_trxstatus* status = nullptr;
rvec mu_tot;
t_trxframe rerun_fr;
- gmx_localtop_t top(top_global->ffparams);
+ gmx_localtop_t top(top_global.ffparams);
ForceBuffers f;
gmx_global_stat_t gstat;
gmx_shellfc_t* shellfc;
int nstglobalcomm = 1;
const bool bNS = true;
- const SimulationGroups* groups = &top_global->groups;
+ const SimulationGroups* groups = &top_global.groups;
if (ir->eI == IntegrationAlgorithm::Mimic)
{
- auto nonConstGlobalTopology = const_cast<gmx_mtop_t*>(top_global);
- nonConstGlobalTopology->intermolecularExclusionGroup = genQmmmIndices(*top_global);
+ auto nonConstGlobalTopology = const_cast<gmx_mtop_t*>(&top_global);
+ nonConstGlobalTopology->intermolecularExclusionGroup = genQmmmIndices(top_global);
}
int* fep_state = MASTER(cr) ? &state_global->fep_state : nullptr;
gmx::ArrayRef<real> lambda = MASTER(cr) ? state_global->lambda : gmx::ArrayRef<real>();
simulationsShareState,
ms);
gmx::EnergyOutput energyOutput(mdoutf_get_fp_ene(outf),
- *top_global,
+ top_global,
*ir,
pull_work,
mdoutf_get_fp_dhdl(outf),
runScheduleWork->simulationWork.useGpuPme);
{
- double io = compute_io(ir, top_global->natoms, *groups, energyOutput.numEnergyTerms(), 1);
+ double io = compute_io(ir, top_global.natoms, *groups, energyOutput.numEnergyTerms(), 1);
if ((io > 2000) && MASTER(cr))
{
fprintf(stderr, "\nWARNING: This run will generate roughly %.0f Mb of data\n\n", io);
TRUE,
1,
state_global,
- *top_global,
+ top_global,
*ir,
imdSession,
pull_work,
/* 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();
checkNumberOfBondedInteractions(mdlog,
cr,
totalNumberOfBondedInteractions,
- *top_global,
+ top_global,
&top,
makeConstArrayRef(state->x),
state->box,
fprintf(stderr,
"starting md rerun '%s', reading coordinates from"
" input trajectory '%s'\n\n",
- *(top_global->name),
+ *(top_global.name),
opt2fn("-rerun", nfile, fnm));
if (mdrunOptions.verbose)
{
if (MASTER(cr))
{
isLastStep = !read_first_frame(oenv, &status, opt2fn("-rerun", nfile, fnm), &rerun_fr, TRX_NEED_X);
- if (rerun_fr.natoms != top_global->natoms)
+ if (rerun_fr.natoms != top_global.natoms)
{
gmx_fatal(FARGS,
"Number of atoms in trajectory (%d) does not match the "
"run input file (%d)\n",
rerun_fr.natoms,
- top_global->natoms);
+ top_global.natoms);
}
if (ir->pbcType != PbcType::No)
bMasterState,
nstglobalcomm,
state_global,
- *top_global,
+ top_global,
*ir,
imdSession,
pull_work,
checkNumberOfBondedInteractions(mdlog,
cr,
totalNumberOfBondedInteractions,
- *top_global,
+ top_global,
&top,
makeConstArrayRef(state->x),
state->box,