OpenCL implementation not doing device sanity checks - Redmine #2420
Archive from user: Aleksei Iupinov
is_gmx_supported_gpu_id() calls do_sanity_checks() in CUDA implementation, even launching a dummy GPU kernel, but does nothing of the kind in OpenCL, only looking at device vendor and OS version.
Therefore, disabling devices with “sudo nvidia-smi -c 2” causes OpenCL mdrun to fail with CL_DEVICE_NOT_AVAILABLE on context creation.
(from redmine: issue id 2420, created on 2018-02-23 by gmxdefault, closed on 2018-12-22)
- Relations:
- relates #2405 (closed)
- relates #2515 (closed)
- Changesets:
- Revision 383240b1 by Aleksei Iupinov on 2018-12-22T01:40:17Z:
Add a sanity check for OpenCL devices
Introduced some type traits to support RAII types for OpenCL handles,
so that we can safely free resources when responding to OpenCL API
error codes, and do so with usefully descriptive error messages.
The new infrastructure is used to implement a check that an OpenCL GPU
can execute a dummy kernel.
Fixed some broken docs, and updated some function naming for new
style.
Fixes #2420
Change-Id: Id99786d24f77b4b56669b5cfcd3a39aa0116cfca