Gromacs-2020.3 with OpenCL

Dear All,

Does anyone know how to install gromacs-2020.3 with OpenCL GPU? I tried to install it by cmake, but it did not work. My CPU is Intel Core i5-8265U 1.6 GHz. My GPU is Intel UHD Grapics 620. My operating system is Ubuntu 18.04. Without OpenCL GPU, installation had been done without any trouble.

Sincerely,

Moto

Documented here http://manual.gromacs.org/current/install-guide/index.html#opencl-gpu-acceleration. If you still have a problem, say exactly what the problem is with full error message and such.

Dear Mr. Schulz,

I appreciate your quick response. I am not familiar with computer language. I downloaded header and library files (https://github.com/KhronosGroup/OpenCL-ICD-Loader). Then I placed header files under /usr/local/CL, and a libray file as /home/moto/OpenCL-ICD-Loader/build/test/driver_stub/libOpenCLDriverStub.so.

Then I executed cmake under /home/moto/gromacs-2020.3/build as follows:

cmake … -DOpenCL_INCLUDE_DIR=/usr/local -DOpenCL_LIBRARY=/home/moto/OpenCL-ICD-Loader/build/test/driver_stub/libOpenCLDriverStub.so -DGMX_GPU=ON -DGMX_USE_OPENCL=ON -DGMX_OPENCL_NB_CLUSTER_SIZE=4 -DGMX_BUILD_OWN_FFTW=ON -DREGRESSIONTEST_DOWNLOAD=ON

It looked OK. But when I executed make, I got error messages as follows. Could you please let me know what went wrong?

Sincerely,

Moto

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clBuildProgram’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clEnqueueNDRangeKernel’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clSetKernelArg’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clReleaseMemObject’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clFinish’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetCommandQueueInfo’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clReleaseContext’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clReleaseEvent’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clEnqueueWriteBuffer’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clEnqueueReadBuffer’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clEnqueueBarrierWithWaitList’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clEnqueueFillBuffer’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetProgramBuildInfo’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clCreateContext’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetDeviceIDs’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetContextInfo’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetDeviceInfo’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clReleaseCommandQueue’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetPlatformIDs’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clWaitForEvents’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetEventProfilingInfo’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clCreateProgramWithBinary’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clCreateCommandQueue’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetKernelWorkGroupInfo’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clRetainEvent’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clRetainContext’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clReleaseProgram’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clFlush’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetProgramInfo’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clCreateKernel’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clCreateBuffer’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clCreateKernelsInProgram’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clCreateProgramWithSource’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clReleaseKernel’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clEnqueueMarkerWithWaitList’

…/…/lib/libgromacs.so.5.0.0: undefined reference to `clGetKernelInfo’

collect2: error: ld returned 1 exit status

share/template/CMakeFiles/template.dir/build.make:97: recipe for target ‘bin/template’ failed

make[2]: *** [bin/template] Error 1

CMakeFiles/Makefile2:2219: recipe for target ‘share/template/CMakeFiles/template.dir/all’ failed

make[1]: *** [share/template/CMakeFiles/template.dir/all] Error 2

Makefile:162: recipe for target ‘all’ failed

make: *** [all] Error 2