Task #2522

Feature #2054: PME on GPU

Task #2453: PME OpenCL porting effort

OpenCL context duplication

Added by Aleksei Iupinov 3 months ago. Updated 3 months ago.

Target version:


Current PME OpenCL code creates its own cl_context in PmeGpuProgramImpl, based on input gmx_device_info_t *.
NB with OpenCL also creates its own OpenCL context. OpenCL contexts can correspond to multiple devices:
NB and PME not sharing same cl_context on the rank can even be detrimental - it's possible they would not have access to each other's cl_mem's.
cl_context management should be taken away from PmeGpuProgramImpl/nbnxn_gpu_create_context() and put into a new class, which would get constructed from a set of gmx_device_info_t *.
The instance of this class should get created based on the GPU task assignment.
PME/NB still need to store references to this object to get the cl_context/gmx_device_info_t * out of it.

Associated revisions

Revision b2a95c76 (diff)
Added by Aleksei Iupinov 3 months ago

Support persistent device context-derived data in PME tests

PME OpenCL will need to not recompile kernels for running each
unit test. With this in mind, a persistent PmeGpuProgram class
is tasked with GPU kernel setup, and passed around, using a typedef.
The purpose of the class is to hold the PME program data that should
only be set up once and live forever for the given device context.
PmeGpuProgramImpl structure is now tasked with managing
function pointers to the CUDA kernels' instances, and will later
be tasked with compiling OpenCL kernels.

Refs #2453, #2522

Change-Id: I85a01bfc92ec3a108825414b14e2be3731433c9a


#1 Updated by Aleksei Iupinov 3 months ago

  • Description updated (diff)

#2 Updated by Aleksei Iupinov 3 months ago

  • Description updated (diff)

#3 Updated by Gerrit Code Review Bot 3 months ago

Gerrit received a related patchset '19' for Issue #2522.
Uploader: Mark Abraham ()
Change-Id: gromacs~master~I85a01bfc92ec3a108825414b14e2be3731433c9a
Gerrit URL:

Also available in: Atom PDF