Search code examples
pythoncudanumba

Numba GPU support for NVIDIA with compute capability 2.1


I can't seem to understand the requirements for numba concerning cuda support. In here (https://numba.pydata.org/numba-doc/latest/cuda/overview.html) it states that I need compute capability higher than 2.0, I have an NVIDIA GeForce 820M which has 2.1, so I would think that's ok, but here (https://numba.readthedocs.io/en/stable/user/installing.html) it states that I need 3.0 or higher and even then it's discontinued. Plus, when I run "nvcc --version" from the command prompt I get

nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2022 NVIDIA Corporation Built on Tue_May__3_19:00:59_Pacific_Daylight_Time_2022 Cuda compilation tools, release 11.7, V11.7.64 Build cuda_11.7.r11.7/compiler.31294372_0

but I keep getting an error when running

from numba import cuda
gpu = cuda.get_current_device()

as:

CudaDriverError: driver missing function: cuDeviceGetUuid. Requires CUDA 9.2 or above.

What am I doing wrong?


Solution

  • There are a lot of confusion in this question, so let's break it down.

    You have a very old GPU. So old that support for it was deprecated and removed from CUDA in 2017. No modern version of Numba will support it.

    In here (https://numba.pydata.org/numba-doc/latest/cuda/overview.html) it states that I need compute capability higher than 2.0

    I don't think that Numba has ever actually supported compute 2.x devices. It relies on libnvvm (NVIDIA's lvvm to PTX compiler library) and that has only ever supported compute 3.x and newer devices, IIRC. But in any case, support for your GPU, if it existed, was removed from CUDA (and by extension Numba) a long time ago.

    when I run "nvcc --version" from the command prompt I get

    nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2022 NVIDIA Corporation Built on Tue_May__3_19:00:59_Pacific_Daylight_Time_2022 Cuda compilation tools, release 11.7, V11.7.64 Build cuda_11.7.r11.7/compiler.31294372_0

    but I keep getting an error when running

    The nvcc version you have is unrelated to whether your GPU is supported, and whether Numba will work correctly. CUDA 11.7 doesn't support your GPU. CUDA 8.0 was the last CUDA release with compute 2.1 support, as far as I am aware.

    but I keep getting an error when running

    from numba import cuda gpu = cuda.get_current_device()

    as:

    CudaDriverError: driver missing function: cuDeviceGetUuid. Requires CUDA 9.2 or above.

    This is because your very old GPU requires a very old driver family and that driver family can't support any functions added to CUDA after CUDA 9.0 was released. The Numba internals are telling you they failed to work because your driver is too old. But there is no newer driver for your GPU that will work.

    In summary, you have an old GPU. It has no CUDA support. It has no Numba support (and probably never had any Numba support). Your only solution is to use a different GPU.