Take over management of OpenCL context from PME and NBNXM
[alexxy/gromacs.git] / src / gromacs / ewald / pme_gpu_program.h
index 32c33442eb5f79c4f1308ccfd009cebe57974e4e..d4dbdf449d9b17eba6edd7b5b5b0af8868a8efdd 100644 (file)
 
 #include <memory>
 
+class DeviceContext;
+
 struct PmeGpuProgramImpl;
 struct DeviceInformation;
 
 class PmeGpuProgram
 {
 public:
-    explicit PmeGpuProgram(const DeviceInformation& deviceInfo);
+    explicit PmeGpuProgram(const DeviceInformation& deviceInfo, const DeviceContext& deviceContext);
     ~PmeGpuProgram();
 
     // TODO: design getters for information inside, if needed for PME, and make this private?
@@ -69,6 +71,7 @@ using PmeGpuProgramStorage = std::unique_ptr<PmeGpuProgram>;
 /*! \brief
  * Factory function used to build persistent PME GPU program for the device at once.
  */
-PmeGpuProgramStorage buildPmeGpuProgram(const DeviceInformation* /*deviceInfo*/);
+PmeGpuProgramStorage buildPmeGpuProgram(const DeviceInformation& /*deviceInfo*/,
+                                        const DeviceContext& /* deviceContext */);
 
 #endif