Skip to content

Commit

Permalink
Add support for cuda 11.1 and compute 8.6
Browse files Browse the repository at this point in the history
  • Loading branch information
umar456 committed Oct 5, 2020
1 parent c903e57 commit db3c333
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
11 changes: 10 additions & 1 deletion CMakeModules/select_compute_arch.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -95,13 +95,22 @@ endif()

if(CUDA_VERSION VERSION_GREATER "11.0" OR CUDA_VERSION VERSION_EQUAL "11.0")
list(APPEND CUDA_KNOWN_GPU_ARCHITECTURES "Ampere")
list(APPEND CUDA_COMMON_GPU_ARCHITECTURES "8.0" "8.0+PTX")
list(APPEND CUDA_COMMON_GPU_ARCHITECTURES "8.0")
list(APPEND CUDA_ALL_GPU_ARCHITECTURES "8.0")

list(REMOVE_ITEM CUDA_KNOWN_GPU_ARCHITECTURES "Kepler+Tegra")
list(REMOVE_ITEM CUDA_KNOWN_GPU_ARCHITECTURES "Kepler")
list(REMOVE_ITEM CUDA_COMMON_GPU_ARCHITECTURES "3.0" "3.2")

if(CUDA_VERSION VERSION_GREATER "11.1" OR CUDA_VERSION VERSION_EQUAL "11.1")
list(APPEND CUDA_ALL_GPU_ARCHITECTURES "8.6")
endif()

if(CUDA_VERSION VERSION_GREATER "11.1" OR CUDA_VERSION VERSION_EQUAL "11.1"
AND CUDA_VERSION VERSION_LESS "12.0")
list(APPEND CUDA_COMMON_GPU_ARCHITECTURES "8.0+PTX")
endif()

if(CUDA_VERSION VERSION_LESS "12.0")
set(CUDA_LIMIT_GPU_ARCHITECTURE "9.0")
endif()
Expand Down
5 changes: 4 additions & 1 deletion src/backend/cuda/device_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ static const int jetsonComputeCapabilities[] = {

// clang-format off
static const cuNVRTCcompute Toolkit2MaxCompute[] = {
{11010, 8, 0, 0},
{11000, 8, 0, 0},
{10020, 7, 5, 2},
{10010, 7, 5, 2},
Expand All @@ -115,6 +116,7 @@ static const cuNVRTCcompute Toolkit2MaxCompute[] = {
// clang-format off
static const ToolkitDriverVersions
CudaToDriverVersion[] = {
{11010, 455.23f, 456.38f},
{11000, 450.51f, 451.48f},
{10020, 440.33f, 441.22f},
{10010, 418.39f, 418.96f},
Expand Down Expand Up @@ -237,7 +239,8 @@ static inline int compute2cores(unsigned major, unsigned minor) {
{0x10, 8}, {0x11, 8}, {0x12, 8}, {0x13, 8}, {0x20, 32},
{0x21, 48}, {0x30, 192}, {0x32, 192}, {0x35, 192}, {0x37, 192},
{0x50, 128}, {0x52, 128}, {0x53, 128}, {0x60, 64}, {0x61, 128},
{0x62, 128}, {0x70, 64}, {0x75, 64}, {0x80, 64}, {-1, -1},
{0x62, 128}, {0x70, 64}, {0x75, 64}, {0x80, 64}, {0x86, 128},
{-1, -1},
};

for (int i = 0; gpus[i].compute != -1; ++i) {
Expand Down

0 comments on commit db3c333

Please sign in to comment.