]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Error when using CUDA 12 with our own backend 15286/head
authorBruno Turcksin <bruno.turcksin@gmail.com>
Tue, 13 Jun 2023 15:15:57 +0000 (15:15 +0000)
committerBruno Turcksin <bruno.turcksin@gmail.com>
Tue, 13 Jun 2023 16:15:49 +0000 (16:15 +0000)
cmake/configure/configure_40_cuda.cmake
doc/external-libs/cuda.html

index 46b9e9c205a7b312f97cd1f1239834a0783334ab..6ac84c113ec5bd29bc5a830dc883160a3fbe560b 100644 (file)
@@ -61,6 +61,16 @@ macro(feature_cuda_find_external var)
         )
       endif()
 
+      #
+      # We do not support CUDA 12.0 and newer:
+      #
+      if(CUDA_VERSION VERSION_GREATER_EQUAL 12.0)
+        message(FATAL_ERROR "\n"
+          "deal.II's own CUDA backend does not support CUDA version 12.0 or newer.\n"
+          "Instead, configure Kokkos with CUDA enabled."
+        )
+      endif()
+
       #
       # CUDA Toolkit 10 is incompatible with C++17.
       # Make sure that deal.II is configured appropriately
index 5d1c9582ef201c427e83f0edbb552f17d5fe7125..3eed499c0d998aef607e026a3a17178bffe19bbb 100644 (file)
     <p>
       To compile and run CUDA code, you need to use an external Kokkos
       installation that has been configured with CUDA support.
-      This, in turn, requires a CUDA-enabled GPU, appropriate
-      drivers, the CUDA toolkit, and the nvcc compiler. Unlike other libraries,
-      you need special hardware and compiler to enable CUDA. Because the
-      hardware is always evolving, older GPUs do not support all the
-      capabilities of newer ones. In order to use CUDA with deal.II, you will
-      need your GPU to have compute capability 6.0 or higher. Independently
-      from the GPU itself, you also need a version of CUDA recent enough.
-      deal.II supports CUDA 10.2 and higher.
+
+      To enable deal.II's own CUDA backend, you will need your GPU to have compute
+      capability 6.0 or higher. Independently from the GPU itself, you also need a
+      version of CUDA between 10.2 and 11.8.
     </p>
 
     <p>
-      To configure deal.II with CUDA use the following option:
+      To configure deal.II's own CUDA backend use the following option:
       <pre>
 
         -DDEAL_II_WITH_CUDA=ON
@@ -43,7 +39,6 @@
       supports this feature, you can tell deal.II to use it by configuring with
       <pre>
 
-        -DDEAL_II_WITH_CUDA=ON
         -DDEAL_II_WITH_MPI=ON
         -DDEAL_II_MPI_WITH_DEVICE_SUPPORT=ON
       </pre>

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.