Skip to content

Commit

Permalink
[Unity] downgrade cmake version requirement (apache#16432)
Browse files Browse the repository at this point in the history
downgrade cmake version requirement
  • Loading branch information
Hzfengsy authored Jan 19, 2024
1 parent a42ca7f commit 4e754a7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.24)
cmake_minimum_required(VERSION 3.18)
project(tvm C CXX)

# Utility functions
Expand Down
3 changes: 3 additions & 0 deletions cmake/modules/CUDA.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ if(USE_CUDA)
list(APPEND TVM_RUNTIME_LINKER_LIBS ${CUDA_NVRTC_LIBRARY})

if(NOT DEFINED CMAKE_CUDA_ARCHITECTURES)
if(CMAKE_VERSION VERSION_LESS "3.24")
message(FATAL_ERROR "CMAKE_CUDA_ARCHITECTURES not set. Please upgrade cmake to 3.24 to use native, or set CMAKE_CUDA_ARCHITECTURES manually")
endif()
message(STATUS "CMAKE_CUDA_ARCHITECTURES not set, using native")
set(CMAKE_CUDA_ARCHITECTURES native)
endif()
Expand Down
1 change: 1 addition & 0 deletions tests/scripts/task_config_build_gpu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,4 @@ echo set\(USE_PIPELINE_EXECUTOR ON\) >> config.cmake
echo set\(USE_CUTLASS ON\) >> config.cmake
echo set\(USE_CMSISNN ON\) >> config.cmake
echo set\(USE_MSC ON\) >> config.cmake
echo set\(CMAKE_CUDA_ARCHITECTURES 75\) >> config.cmake

0 comments on commit 4e754a7

Please sign in to comment.