Skip to content

Commit

Permalink
CUDA on MSVC: allow it, but default is OFF
Browse files Browse the repository at this point in the history
  • Loading branch information
DrTimothyAldenDavis committed Dec 23, 2023
1 parent e20fd32 commit a6d317b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
6 changes: 4 additions & 2 deletions SuiteSparse_config/Config/README.md.in
Original file line number Diff line number Diff line change
Expand Up @@ -728,8 +728,10 @@ build type). The static libraries will not be built (since

* `SUITESPARSE_USE_CUDA`:

If set to `ON`, CUDA is enabled for all of SuiteSparse. Default: `ON`.
Ignored for MSVC (CUDA acceleration is disabled on Windows with MSVC).
If set to `ON`, CUDA is enabled for all of SuiteSparse. Default: `ON`,
except for MSVC. CUDA on Windows with MSVC is enabled, but under
development. It may not be fully functional. If you encounter issues,
disable CUDA and post this as an issue on githup.

* `CHOLMOD_USE_CUDA`:

Expand Down
7 changes: 3 additions & 4 deletions SuiteSparse_config/cmake_modules/SuiteSparsePolicy.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
# set ( CMAKE_BUILD_TYPE Debug )
#
# SUITESPARSE_USE_CUDA: if OFF, CUDA is disabled. if ON, CUDA is enabled,
# if available. Ignored for MSVC.
# Default: ON.
# if available. Default: ON.
#
# SUITESPARSE_LOCAL_INSTALL: if true, "cmake --install" will install
# into SuiteSparse/lib and SuiteSparse/include.
Expand Down Expand Up @@ -285,8 +284,8 @@ endif ( )
#-------------------------------------------------------------------------------

if ( MSVC )
# do not attempt to use CUDA on MSVC
set ( SUITESPARSE_USE_CUDA OFF )
option ( SUITESPARSE_USE_CUDA "ON: enable CUDA acceleration for SuiteSparse, OFF (default): do not use CUDA" OFF )
message ( STATUS "CUDA on MSVC is under development and may not be fully functional (it is disabled by default)" )
else ( )
option ( SUITESPARSE_USE_CUDA "ON (default): enable CUDA acceleration for SuiteSparse, OFF: do not use CUDA" ON )
endif ( )
Expand Down

0 comments on commit a6d317b

Please sign in to comment.