Fix CUDA version info in NVML application clock warning
authorErik Lindahl <erik@kth.se>
Fri, 12 Jun 2015 21:16:07 +0000 (23:16 +0200)
committerGerrit Code Review <gerrit@gerrit.gromacs.org>
Tue, 16 Jun 2015 20:38:29 +0000 (22:38 +0200)
Report driver and runtime versions, not the compute capability
of the card (since we already detected the card is recent enough).

Fixes #1706.

Change-Id: Ida8b36203f56dcda20dc367c69dc02586edf40e4

src/gromacs/gmxlib/gpu_utils/gpu_utils.cu

index 3d93445f8d7e4762ea4467215ff1498d7a6bfe28..5614f673e121856bf1f4a947d44b0f39eeb27836 100644 (file)
@@ -298,9 +298,14 @@ static gmx_bool init_gpu_application_clocks(FILE gmx_unused *fplog, int gmx_unus
 #ifndef HAVE_NVML
     if (bGpuCanUseApplicationClocks)
     {
-        md_print_warn( fplog, "NVML support was not found in CUDA library %d.%d, so your GPU of type %s cannot use application clock support to improve performance.\n",
-                       prop->major,
-                       prop->minor,
+        int cuda_driver  = 0;
+        int cuda_runtime = 0;
+        cudaDriverGetVersion(&cuda_driver);
+        cudaRuntimeGetVersion(&cuda_runtime);
+        md_print_warn( fplog, "Note: NVML support was not found (CUDA runtime %d.%d, driver %d.%d), so your\n"
+                       "      %s GPU cannot use application clock support to improve performance.\n",
+                       cuda_runtime/1000, cuda_runtime%100,
+                       cuda_driver/1000, cuda_driver%100,
                        prop->name );
     }
     return true;