Fix conditions for building StatePropagatorDataGpu
authorSzilárd Páll <pall.szilard@gmail.com>
Thu, 10 Oct 2019 19:56:16 +0000 (21:56 +0200)
committerSzilárd Páll <pall.szilard@gmail.com>
Thu, 10 Oct 2019 19:56:16 +0000 (21:56 +0200)
StatePropagatorDataGpu was only build when GPU update was active rather
than when GPU buffer ops is active.

Change-Id: I6d2efa73c4896a293155c0853a32b8cedf3d23a6

src/gromacs/mdrun/runner.cpp

index 203064853b0ed282c27c4f807a2524700b458f94..fdc93ac07e2827483542a22c9371b5977d4f2c8d 100644 (file)
@@ -1530,7 +1530,7 @@ int Mdrunner::mdrunner()
         const bool useModularSimulator = inputIsCompatibleWithModularSimulator && !(getenv("GMX_DISABLE_MODULAR_SIMULATOR") != nullptr);
 
         std::unique_ptr<gmx::StatePropagatorDataGpu> stateGpu;
-        if (gpusWereDetected && ((useGpuForPme && thisRankHasDuty(cr, DUTY_PME)) || useGpuForUpdate))
+        if (gpusWereDetected && ((useGpuForPme && thisRankHasDuty(cr, DUTY_PME)) || devFlags.enableGpuBufferOps))
         {
             const void         *pmeStream      = pme_gpu_get_device_stream(fr->pmedata);
             const void         *localStream    = fr->nbv->gpu_nbv != nullptr ? Nbnxm::gpu_get_command_stream(fr->nbv->gpu_nbv, Nbnxm::InteractionLocality::Local) : nullptr;