Enable GPU update with DD when GPU comm features are enabled
[alexxy/gromacs.git] / src / gromacs / mdrun / md.cpp
index 4f163faf865f7ef5c3ee9caadb0fee5ec2bf86e8..ee6a81fb82ca911934151251b7534b94ce2145e3 100644 (file)
@@ -334,8 +334,11 @@ void gmx::LegacySimulator::do_md()
 
     if (useGpuForUpdate)
     {
-        GMX_RELEASE_ASSERT(!DOMAINDECOMP(cr),
-                           "Domain decomposition is not supported with the GPU update.\n");
+        GMX_RELEASE_ASSERT(!DOMAINDECOMP(cr)
+                                   || (simulationWork.useGpuDirectCommunication
+                                       && simulationWork.useGpuPmePpCommunication),
+                           "Domain decomposition is not supported with the GPU update when not "
+                           "using direct GPU communication.\n");
         GMX_RELEASE_ASSERT(useGpuForPme || (useGpuForNonbonded && simulationWork.useGpuBufferOps),
                            "Either PME or short-ranged non-bonded interaction tasks must run on "
                            "the GPU to use GPU update.\n");