Commit 5b0da217 authored by COULAUD Olivier's avatar COULAUD Olivier

Improvments

parent f9aca273
......@@ -103,10 +103,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
CMAKE_DEPENDENT_OPTION( SCALFMM_USE_AVX2 "Set to ON to compile with AVX support (and use intrinsec AVX2 P2P)" ON "CPUOPTION_AVX2" OFF )
if( SCALFMM_ONLY_DEVEL )
# OPENMP 4/5 support
option( OPENMP_SUPPORT_COMMUTE "Set to ON to let tasks commute (KSTAR/StarPU compiler only)" OFF )
option( OPENMP_SUPPORT_PRIORITY "Set to ON to enable tasks priority (KSTAR/StarPU compiler only)" OFF )
option( OPENMP_SUPPORT_TASK_NAME "Set to ON to enable a taskname clause for tasks (KSTAR/StarPU compiler only)" OFF )
if(CMAKE_CXX_COMPILER_ID STREQUAL "Intel")
option( SCALFMM_USE_OMP4 "Set to ON to disable the gcc/intel omp4" OFF )
else()
......@@ -116,7 +112,13 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
# SIMGRID and peformance models options
option( SCALFMM_SIMGRID_NODATA "Set to ON to avoid the allocation of numerical parts in the group tree" OFF )
option( STARPU_SIMGRID_MLR_MODELS "Set to ON to enable MLR models need for calibration and simulation" OFF )
# OPENMP 4/5 support
option( OPENMP_SUPPORT_PRIORITY "Set to ON to enable tasks priority (OMP4.x/KSTAR/StarPU compiler only)" OFF )
# STARPU options
CMAKE_DEPENDENT_OPTION(OPENMP_SUPPORT_COMMUTE "Set to ON to let tasks commute (KSTAR/StarPU compiler only)" OFF
"SCALFMM_USE_STARPU" OFF)
CMAKE_DEPENDENT_OPTION(OPENMP_SUPPORT_TASK_NAME "Set to ON to enable a taskname clause for tasks (KSTAR/StarPU compiler only)" OFF
"SCALFMM_USE_STARPU" OFF)
CMAKE_DEPENDENT_OPTION(SCALFMM_STARPU_USE_COMMUTE "Set to ON to enable commute with StarPU" ON "SCALFMM_USE_STARPU" OFF)
CMAKE_DEPENDENT_OPTION(SCALFMM_STARPU_USE_REDUX "Set to ON to enable redux with StarPU" OFF "SCALFMM_USE_STARPU" OFF)
CMAKE_DEPENDENT_OPTION(SCALFMM_STARPU_USE_PRIO "Set to ON to enable priority with StarPU" ON "SCALFMM_USE_STARPU" OFF)
......@@ -298,7 +300,7 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
find_package(MPI REQUIRED)
if(MPI_FOUND)
if (MPI_CXX_FOUND)
message("MPI_CXX is in the place")
# message("MPI_CXX is in the place")
if (MPI_CXX_INCLUDE_PATH)
include_directories( ${MPI_CXX_INCLUDE_PATH} )
endif()
......@@ -529,7 +531,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
if( SCALFMM_USE_STARPU )
# CUDA could be used with StarPU enabled
option( SCALFMM_USE_CUDA "Set to ON to use CUDA with StarPU" OFF )
message( STATUS "SCALFMM_USE_CUDA = ${SCALFMM_USE_CUDA}" )
if(SCALFMM_USE_CUDA)
execute_process(COMMAND nvcc --version ERROR_VARIABLE cuda_error_output OUTPUT_QUIET)
if(cuda_error_output)
......@@ -542,7 +543,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
# This is needed to remove backslash after space in ADD_CUSTOM_COMMAND
separate_arguments(CUSTOM_CUDA_FLAGS)
message( STATUS "CUSTOM_CUDA_FLAGS = ${CUSTOM_CUDA_FLAGS}" )
find_package(CUDA REQUIRED)
if (CUDA_INCLUDE_DIRS)
......@@ -556,7 +556,7 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
endif()
# Find StarPU with a list of optional components
set(SCALFMM_STARPU_VERSION "1.1" CACHE STRING "oldest STARPU version desired")
set(SCALFMM_STARPU_VERSION "1.2" CACHE STRING " STARPU version desired")
# create list of components in order to make a single call to find_package(starpu...)
set(STARPU_COMPONENT_LIST "HWLOC")
......@@ -564,13 +564,24 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
if(SCALFMM_USE_CUDA)
list(APPEND STARPU_COMPONENT_LIST "CUDA")
else()
list(APPEND FUSE_LIST "CUDA")
list(APPEND FUSE_LIST "CUDA")
endif()
if(SCALFMM_USE_MPI)
list(APPEND STARPU_COMPONENT_LIST "MPI")
endif()
# TODO: replace this by a component of find starpu
OPTION( SCALFMM_USE_OPENCL "Set to ON to use OPENCL with StarPU" OFF )
if(SCALFMM_USE_OPENCL)
list(APPEND STARPU_COMPONENT_LIST "OPENCL")
# include_directories($ENV{OPENCL_INC})
# SET(SCALFMM_LIBRARIES "${SCALFMM_LIBRARIES};-L$ENV{OPENCL_LIB};-lOpenCL")
else()
list(APPEND FUSE_LIST "OPENCL")
endif()
find_package(STARPU ${SCALFMM_STARPU_VERSION} REQUIRED
COMPONENTS ${STARPU_COMPONENT_LIST})
......@@ -578,6 +589,7 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
# the RPATH to be used when installing
list(APPEND CMAKE_INSTALL_RPATH "${HWLOC_LIBRARY_DIRS}")
endif()
if(FXT_FOUND AND FXT_LIBRARY_DIRS)
# the RPATH to be used when installing
list(APPEND CMAKE_INSTALL_RPATH "${FXT_LIBRARY_DIRS}")
......@@ -601,9 +613,8 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
set(SCALFMM_LIBRARIES "${SCALFMM_LIBRARIES};-l${starpu_lib}")
endif()
endforeach()
else()
# StarPU not found
list(APPEND FUSE_LIST "STARPU")
endif()
......@@ -614,7 +625,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
endif()
# Message
message(STATUS " STARPU_LIBRARIES = ${STARPU_LIBRARIES}")
if (STARPU_INCLUDE_DIRS)
message(STATUS " STARPU_INCLUDES = ${STARPU_INCLUDE_DIRS}")
set(SCALFMM_INCLUDES "${SCALFMM_INCLUDES}; ${STARPU_INCLUDE_DIRS}")
......@@ -624,15 +634,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
set(SCALFMM_INCLUDES "${SCALFMM_INCLUDES};$ENV{SIMGRID_INCLUDE}")
message(STATUS " Adding SIMGRID = $ENV{SIMGRID_INCLUDE}")
# TODO: replace this by a component of find starpu
OPTION( SCALFMM_USE_OPENCL "Set to ON to use OPENCL with StarPU" OFF )
MESSAGE( STATUS "SCALFMM_USE_OPENCL = ${SCALFMM_USE_OPENCL}" )
if(SCALFMM_USE_OPENCL)
include_directories($ENV{OPENCL_INC})
SET(SCALFMM_LIBRARIES "${SCALFMM_LIBRARIES};-L$ENV{OPENCL_LIB};-lOpenCL")
else()
list(APPEND FUSE_LIST "OPENCL")
endif()
else()
list(APPEND FUSE_LIST "STARPU")
list(APPEND FUSE_LIST "CUDA")
......@@ -988,6 +989,12 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules/morse_
message(STATUS "SCALFMM_USE_FFT = ${SCALFMM_USE_FFT}")
message(STATUS "SCALFMM_USE_MKL = ${SCALFMM_USE_MKL}")
#
if(SCALFMM_USE_STARPU)
message( STATUS "SCALFMM_USE_STARPU = ${SCALFMM_USE_STARPU}" )
message(STATUS " STARPU_LIBRARIES = ${STARPU_LIBRARIES}")
message( STATUS "SCALFMM_USE_CUDA = ${SCALFMM_USE_CUDA}" )
MESSAGE( STATUS "SCALFMM_USE_OPENCL = ${SCALFMM_USE_OPENCL}" )
endif(SCALFMM_USE_STARPU)
message(STATUS "CMAKE_CXX_FLAGS_TYPE = ${CMAKE_CXX_FLAGS_TYPE}")
message(STATUS "CMAKE_CXX_FLAGS = ${CMAKE_CXX_FLAGS}")
message(STATUS "SCALFMM_CXX_FLAGS = ${SCALFMM_CXX_FLAGS}")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment