Merge branch 'origin/release-2020' into master
[alexxy/gromacs.git] / src / gromacs / mdlib / lincs_cuda.cu
index 04d7b751b24aa9e7aaef162ef68eaf06e25db085..1a48c3bc955bc92b089c4d1ba4cfccd513948897 100644 (file)
@@ -40,8 +40,6 @@
  * using CUDA, including class initialization, data-structures management
  * and GPU kernel.
  *
- * \note Management of periodic boundary should be unified with SETTLE and
- *       removed from here.
  * \todo Reconsider naming, i.e. "cuda" suffics should be changed to "gpu".
  *
  * \author Artem Zhmurov <zhmurov@gmail.com>
@@ -435,7 +433,8 @@ void LincsCuda::apply(const float3* d_x,
                       float3*       d_v,
                       const real    invdt,
                       const bool    computeVirial,
-                      tensor        virialScaled)
+                      tensor        virialScaled,
+                      const PbcAiuc pbcAiuc)
 {
     ensureNoPendingCudaError("In CUDA version of LINCS");
 
@@ -479,6 +478,8 @@ void LincsCuda::apply(const float3* d_x,
     }
     config.stream = commandStream_;
 
+    kernelParams_.pbcAiuc = pbcAiuc;
+
     const auto kernelArgs =
             prepareGpuKernelArguments(kernelPtr, config, &kernelParams_, &d_x, &d_xp, &d_v, &invdt);
 
@@ -943,9 +944,4 @@ void LincsCuda::set(const t_idef& idef, const t_mdatoms& md)
                        GpuApiCallBehavior::Sync, nullptr);
 }
 
-void LincsCuda::setPbc(const t_pbc* pbc)
-{
-    setPbcAiuc(pbc->ndim_ePBC, pbc->box, &kernelParams_.pbcAiuc);
-}
-
 } // namespace gmx