Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
openfpm_vcluster
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Sbalzarini Lab
Software
Parallel Computing
OpenFPM
openfpm_vcluster
Commits
821c8b27
Commit
821c8b27
authored
4 years ago
by
Pietro Incardona
Browse files
Options
Downloads
Patches
Plain Diff
Fixing installation for CUDA
parent
c645eebf
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#2637
passed
4 years ago
Stage: build
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
CMakeLists.txt
+10
-26
10 additions, 26 deletions
CMakeLists.txt
with
10 additions
and
26 deletions
CMakeLists.txt
+
10
−
26
View file @
821c8b27
...
...
@@ -15,36 +15,17 @@ set(PETSC_ROOT CACHE PATH "If compiling with linear algebra indicate the PETSC r
set
(
ALPAKA_ROOT CACHE PATH
"Alpaka root path"
)
set
(
CUDA_ON_CPU CACHE BOOL
"Make Cuda work on heap"
)
if
(
ENABLE_GPU
)
set
(
CUDA_ON_CPU OFF
)
enable_language
(
CUDA
)
find_package
(
CUDA
)
endif
()
set
(
ENV{PETSC_DIR}
${
PETSC_ROOT
}
)
set
(
CMAKE_CXX_STANDARD 14
)
set
(
CMAKE_CUDA_STANDARD 14
)
if
(
ENABLE_GPU
)
enable_language
(
CUDA
)
find_package
(
CUDA
)
if
(
CUDA_VERSION_MAJOR EQUAL 9 AND CUDA_VERSION_MINOR EQUAL 2
)
message
(
"CUDA is compatible"
)
set
(
WARNING_SUPPRESSION_AND_OPTION_NVCC -Xcudafe
"--display_error_number --diag_suppress=611 --diag_suppress=2885 --diag_suppress=2886 --diag_suppress=2887 --diag_suppress=2888 --diag_suppress=186 --diag_suppress=111"
--expt-extended-lambda
)
elseif
(
CUDA_VERSION_MAJOR EQUAL 10 AND CUDA_VERSION_MINOR EQUAL 1
)
message
(
"CUDA is compatible"
)
set
(
WARNING_SUPPRESSION_AND_OPTION_NVCC -Xcudafe
"--display_error_number --diag_suppress=2931 --diag_suppress=2930 --diag_suppress=2929 --diag_suppress=2928 --diag_suppress=1835 --diag_suppress=128 --diag_suppress=186 --diag_suppress=611 "
--expt-extended-lambda
)
elseif
(
CUDA_VERSION_MAJOR EQUAL 10 AND CUDA_VERSION_MINOR EQUAL 2
)
message
(
"CUDA is compatible"
)
set
(
WARNING_SUPPRESSION_AND_OPTION_NVCC -Xcudafe
"--display_error_number --diag_suppress=2976 --diag_suppress=2977 --diag_suppress=2979 --diag_suppress=186"
--expt-extended-lambda
)
elseif
(
CUDA_VERSION_MAJOR EQUAL 11 AND CUDA_VERSION_MINOR EQUAL 0
)
message
(
"CUDA is compatible"
)
set
(
WARNING_SUPPRESSION_AND_OPTION_NVCC -Xcudafe
"--display_error_number --diag_suppress=3059 --diag_suppress=3058 --diag_suppress=3057 --diag_suppress=3056 --diag_suppress=611 --diag_suppress=186 --diag_suppress=128"
--expt-extended-lambda
)
elseif
(
CUDA_VERSION_MAJOR EQUAL 11 AND CUDA_VERSION_MINOR EQUAL 1
)
message
(
"CUDA is compatible 11.1"
)
set
(
WARNING_SUPPRESSION_AND_OPTION_NVCC -Xcudafe
"--display_error_number --diag_suppress=3124 --diag_suppress=3126 --diag_suppress=3125 --diag_suppress=3123 --diag_suppress=611 --diag_suppress=186 --diag_suppress=128"
--expt-extended-lambda
)
else
()
message
(
FATAL_ERROR
"CUDA is incompatible, version 9.2 10.1 10.2 and 11.0 is only supported"
)
endif
()
endif
()
find_package
(
Boost 1.72.0 REQUIRED COMPONENTS unit_test_framework iostreams program_options OPTIONAL_COMPONENTS fiber context
)
find_package
(
MPI REQUIRED
)
find_package
(
PETSc
)
...
...
@@ -109,6 +90,9 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/src/config/config_cmake.h.in ${CMAKE_
include_directories
(
SYSTEM
${
MPI_INCLUDE_PATH
}
)
add_subdirectory
(
src
)
add_subdirectory
(
../openfpm_data/ openfpm_data
)
set
(
WARNING_SUPPRESSION_AND_OPTION_NVCC
${
WARNING_SUPPRESSION_AND_OPTION_NVCC
}
PARENT_SCOPE
)
set
(
WARNING_SUPPRESSION_AND_OPTION_NVCC_TEXT
${
WARNING_SUPPRESSION_AND_OPTION_NVCC_TEXT
}
PARENT_SCOPE
)
add_subdirectory
(
src
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment