Instead of just checking, when running updates on GPU, if
there are lambda states that involve constraints or masses
(e.g. if using fep-lambdas) check if any constraints or masses
are actually perturbed.
"Orientation restraints are not supported with the GPU update.\n");
GMX_RELEASE_ASSERT(
ir->efep == efepNO
- || (!haveFreeEnergyType(*ir, efptBONDED) && !haveFreeEnergyType(*ir, efptMASS)),
+ || (!haveFepPerturbedMasses(*top_global) && !havePerturbedConstraints(*top_global)),
"Free energy perturbation of masses and constraints are not supported with the GPU "
"update.");
// The graph is needed, but not supported
errorMessage += "Orientation restraints are not supported.\n";
}
- if (inputrec.efep != efepNO
- && (haveFreeEnergyType(inputrec, efptBONDED) || haveFreeEnergyType(inputrec, efptMASS)))
+ if (inputrec.efep != efepNO && (haveFepPerturbedMasses(mtop) || havePerturbedConstraints(mtop)))
{
errorMessage += "Free energy perturbation for mass and constraints are not supported.\n";
}