CUDA runtime version vs CUDA driver version - what's the difference?

32,851

The CUDA runtime version indicates CUDA compatibility (i.e. version) with respect to the installed cudart (CUDA runtime) library.

The CUDA driver version (as reported here) reports the same information with respect to the driver.

This relates to the driver compatibility model in CUDA. As I am sure you know, a particular CUDA toolkit version (i.e. CUDA runtime library version, nvcc compiler version, etc.) requires a particular minimum driver level for proper use of the codes compiled with that toolkit.

The CUDA driver version (as reported here) effectively reports what CUDA version(s) can be supported by the particular installed driver.

As you've already discovered, it does not report the actual numbered driver version.

Share:
32,851

Related videos on Youtube

einpoklum
Author by

einpoklum

Made my way from the Olympus of Complexity Theory, Probabilistic Combinatorics and Property Testing to the down-to-earth domain of Heterogeneous and GPU Computing, and now I'm hoping to bring the gospel of GPU and massive-regularized parallelism to DBMS architectures. I've post-doc'ed at the DB architecture group in CWI Amsterdam to do (some of) that. I subscribe to most of Michael Richter's critique of StackOverflow; you might want to take the time to read it. If you listen closely you can hear me muttering "Why am I not socratic again already?"

Updated on July 09, 2022

Comments

  • einpoklum
    einpoklum almost 2 years

    The CUDA Runtime API exposes the functions

    • cudaRuntimeGetVersion() and
    • cudaDriverGetVersion()

    (see detailed description here). I was sort of expecting the first one to give me "8.0" (for CUDA 8.0) and the second one to give me the same string as what I'd get from examining nVIDIA's GPU driver kernel module, e.g.

    modinfo nvidia | grep "^version:" | sed 's/^version: *//;'
    

    which on my system is 367.57.

    Now, the first call gives me 8000 - fine, just a weird way to say 8.0 I guess; but the second API call also gives me 8000. So what do both of these mean?

    The Runtime API documentation I linked to doesn't seem to explain this.

  • einpoklum
    einpoklum over 7 years
    (sigh) I get it now. So, I can blame the confusing names, then... Thanks. You've given me a bit of work to do on this.
  • einpoklum
    einpoklum over 7 years
    Also, how exactly do I interpret the 8000? Are the three lowest decimal digits a single 'minor version number', or is it something like 8.0.0 or 8.0.0.0? After all, the CUDA 8.0 release was named 8.0.44 last time I downloaded.
  • Robert Crovella
    Robert Crovella over 7 years
    Study the deviceQuery cuda sample code for interpretation hints. There is no sub-versioning here. 8000 = CUDA 8
  • Breck
    Breck over 5 years
    I still don't get it. Can someone ELI5? How do I check both of these outside of code (is there a way via the command line for both?). Is there also a driver for the graphics card itself (so 3 things: CUDA runtime, CUDA driver, Nvidia drive), or just the 2 things?
  • Robert Crovella
    Robert Crovella over 5 years
    1. There is a GPU driver version. Query it with nvidia-smi. 2. There is a CUDA compatibility version associated with the driver (but there is a 1:1 correspondence between a specific GPU driver version and its associated CUDA compatibility version). The nvidia-smi tool bundled with recent drivers will display the CUDA compatibility version that they have. 3. There is a CUDA runtime version, which would be associated with the runtime API you use to build a particular runtime API code. You can query this with nvcc -v for example, or these last 2 things with deviceQuery sample code.