Skip to content
Snippets Groups Projects
Commit c483c158 authored by Patrick Mours's avatar Patrick Mours Committed by Brecht Van Lommel
Browse files

Cycles: Add Blackwell to Cycles CUDA binaries architectures

Enables building of a Cubin for GPUs based on Blackwell architecture
if CUDA toolkit version 12.8 or higher is installed.
Only added sm_120 to the default set, since it is the one relevant for
consumer GPUs (RTX 5090 etc.) that are generally used with Blender.

Pull Request: https://projects.blender.org/blender/blender/pulls/134170
parent 08d5ffd7
No related branches found
No related tags found
No related merge requests found
...@@ -669,7 +669,7 @@ if(NOT APPLE AND NOT (WIN32 AND CMAKE_SYSTEM_PROCESSOR STREQUAL "ARM64")) ...@@ -669,7 +669,7 @@ if(NOT APPLE AND NOT (WIN32 AND CMAKE_SYSTEM_PROCESSOR STREQUAL "ARM64"))
option(WITH_CYCLES_CUDA_BINARIES "Build Cycles NVIDIA CUDA binaries" OFF) option(WITH_CYCLES_CUDA_BINARIES "Build Cycles NVIDIA CUDA binaries" OFF)
set(CYCLES_CUDA_BINARIES_ARCH set(CYCLES_CUDA_BINARIES_ARCH
sm_30 sm_35 sm_37 sm_50 sm_52 sm_60 sm_61 sm_70 sm_75 sm_86 sm_89 compute_75 sm_30 sm_35 sm_37 sm_50 sm_52 sm_60 sm_61 sm_70 sm_75 sm_86 sm_89 sm_120 compute_75
CACHE STRING "CUDA architectures to build binaries for" CACHE STRING "CUDA architectures to build binaries for"
) )
option(WITH_CYCLES_CUDA_BUILD_SERIAL "\ option(WITH_CYCLES_CUDA_BUILD_SERIAL "\
......
...@@ -11,7 +11,7 @@ buildbot: ...@@ -11,7 +11,7 @@ buildbot:
cuda11: cuda11:
version: '11.4.1' version: '11.4.1'
cuda12: cuda12:
version: '12.1.1' version: '12.8.0'
hip: hip:
version: '5.7.32000' version: '5.7.32000'
hiprt: hiprt:
......
...@@ -577,6 +577,14 @@ if(WITH_CYCLES_CUDA_BINARIES) ...@@ -577,6 +577,14 @@ if(WITH_CYCLES_CUDA_BINARIES)
else() else()
message(STATUS "CUDA binaries for ${arch} require CUDA 11.1+, skipped.") message(STATUS "CUDA binaries for ${arch} require CUDA 11.1+, skipped.")
endif() endif()
elseif(${arch} MATCHES ".*_10." OR ${arch} MATCHES ".*_120")
if("${CUDA_VERSION}" GREATER_EQUAL 128) # Support for sm_100, sm_101, sm_120 was introduced in CUDA 12.8
set(cuda_nvcc_executable ${CUDA_NVCC_EXECUTABLE})
set(cuda_toolkit_root_dir ${CUDA_TOOLKIT_ROOT_DIR})
set(cuda_version ${CUDA_VERSION})
else()
message(STATUS "CUDA binaries for ${arch} require CUDA 12.8+, skipped.")
endif()
else() else()
set(cuda_nvcc_executable ${CUDA_NVCC_EXECUTABLE}) set(cuda_nvcc_executable ${CUDA_NVCC_EXECUTABLE})
set(cuda_toolkit_root_dir ${CUDA_TOOLKIT_ROOT_DIR}) set(cuda_toolkit_root_dir ${CUDA_TOOLKIT_ROOT_DIR})
......
...@@ -62,8 +62,8 @@ ...@@ -62,8 +62,8 @@
# define GPU_KERNEL_MAX_REGISTERS 48 # define GPU_KERNEL_MAX_REGISTERS 48
# endif # endif
/* 7.x, 8.x */ /* 7.x, 8.x, 12.x */
#elif __CUDA_ARCH__ <= 899 #elif __CUDA_ARCH__ <= 1299
# define GPU_MULTIPRESSOR_MAX_REGISTERS 65536 # define GPU_MULTIPRESSOR_MAX_REGISTERS 65536
# define GPU_MULTIPROCESSOR_MAX_BLOCKS 32 # define GPU_MULTIPROCESSOR_MAX_BLOCKS 32
# define GPU_BLOCK_MAX_THREADS 1024 # define GPU_BLOCK_MAX_THREADS 1024
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment