Which GCC version is compatible with CUDA-11.8?

Hi,
What is the default working GCC version with CUDA 11.8? Although I have downloaded CUDA-11.8 for Ubuntu 22.04, the installer doesn’t work with GCC-11. Even I changed the version to GCC-12.3.0 but CUDA installer shows this error:

     CC [M]  /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/os-mlock.o
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c: In function 'nvidia_mmap_numa':
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c:446:19: error: assignment of read-only member 'vm_flags'
     446 |     vma->vm_flags |= VM_MIXEDMAP;
         |                   ^~
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c: In function 'nvidia_mmap_helper':
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c:580:23: error: assignment of read-only member 'vm_flags'
     580 |         vma->vm_flags |= VM_IO | VM_PFNMAP | VM_DONTEXPAND;
         |                       ^~
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c:647:23: error: assignment of read-only member 'vm_flags'
     647 |         vma->vm_flags |= (VM_IO | VM_LOCKED | VM_RESERVED);
         |                       ^~
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c:648:23: error: assignment of read-only member 'vm_flags'
     648 |         vma->vm_flags |= (VM_DONTEXPAND | VM_DONTDUMP);
         |                       ^~
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c:654:23: error: assignment of read-only member 'vm_flags'
     654 |         vma->vm_flags &= ~VM_WRITE;
         |                       ^~
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c:655:23: error: assignment of read-only member 'vm_flags'
     655 |         vma->vm_flags &= ~VM_MAYWRITE;
         |                       ^~
   /tmp/selfgz9515/NVIDIA-Linux-x86_64-520.61.05/kernel/nvidia/nv-mmap.c: In function 'nv_encode_caching':
...
...
make[2]: Target 'modules' not remade because of errors.
make[1]: *** [Makefile:234: __sub-make] Error 2
make[1]: Target 'modules' not remade because of errors.
make[1]: Leaving directory '/usr/src/linux-headers-6.5.0-41-generic'
make: *** [Makefile:82: modules] Error 2
ERROR: The nvidia kernel module was not created.

Any idea about that?

Go here and the Linux Installation Guide in the documentation for the version you want, will tell you.

Installation guides go to 1. Introduction — Installation Guide for Linux 12.5 documentation (nvidia.com) which has a table for CUDA 12.5.

Perhaps I wasn’t clear enough. If you go to the link I posted above, choose the version of toolkit you are interested in and click on the link next to it, “Versioned Online Documentation”, you will find the version specific, “Installation Guide Linux”, there.

1 Like

Sorry but I don’t see “Versioned Online Documentation”. Nonetheless, through Google, I was able to find that:

cuda-11.8 installation document

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.