Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
AGULLO Emmanuel
Chameleon
Commits
143e3551
Commit
143e3551
authored
Dec 09, 2015
by
PRUVOST Florent
Browse files
adapt chameleon to bu used with starpu+simgrid+mpi
parent
ff9c6a27
Changes
8
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
143e3551
...
...
@@ -523,6 +523,9 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
"numerical correctness of algorithms and kernels.
${
ColourReset
}
"
)
endif
()
# Simulation mode: we depend on SimGrid
find_package
(
SIMGRID REQUIRED
)
# CHAMELEON depends on MPI
#-------------------------
if
(
CHAMELEON_USE_MPI
)
...
...
@@ -534,7 +537,11 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
set
(
MPI_C_COMPILER smpicc
)
endif
()
if
(
NOT MPI_C_LIBRARIES
)
set
(
MPI_C_LIBRARIES -lsimgrid
)
set
(
MPI_C_LIBRARIES
"
${
SIMGRID_LIBRARIES
}
"
)
endif
()
if
(
NOT MPI_C_INCLUDE_PATH
)
set
(
MPI_C_INCLUDE_PATH
"
${
SIMGRID_INCLUDE_DIRS
}
"
)
list
(
APPEND MPI_C_INCLUDE_PATH
"
${
SIMGRID_INCLUDE_DIRS
}
/smpi"
)
endif
()
find_package
(
MPI REQUIRED
)
...
...
@@ -559,7 +566,7 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
if
(
CHAMELEON_SCHED_STARPU
)
set
(
CHAMELEON_STARPU_VERSION
"1.1"
CACHE STRING
"oldest STARPU version desired"
)
set
(
CHAMELEON_STARPU_VERSION
"1.1"
CACHE STRING
"oldest STARPU version desired"
)
# create list of components in order to make a single call to find_package(starpu...)
if
(
NOT CHAMELEON_SIMULATION
)
...
...
@@ -595,7 +602,7 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
endforeach
()
list
(
APPEND CMAKE_REQUIRED_FLAGS
"-include"
"starpu_simgrid_wrap.h"
)
string
(
REPLACE
";"
" "
CMAKE_REQUIRED_FLAGS
"
${
CMAKE_REQUIRED_FLAGS
}
"
)
set
(
CMAKE_REQUIRED_LIBRARIES
"
${
STARPU_
SHM_
LIBRARIES
}
"
)
set
(
CMAKE_REQUIRED_LIBRARIES
"
${
STARPU_LIBRARIES
_DEP
}
"
)
check_function_exists
(
starpu_data_idle_prefetch_on_node STARPU_IDLE_PREFETCH_FOUND
)
if
(
STARPU_IDLE_PREFETCH_FOUND
)
add_definitions
(
-DCHAMELEON_USE_STARPU_IDLE_PREFETCH
)
...
...
@@ -606,7 +613,7 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
endif
()
if
(
CHAMELEON_ENABLE_TRACING
)
# check if fxt profiling is accessible in starpu and activate it in chameleon
set
(
CMAKE_REQUIRED_LIBRARIES
"
${
STARPU_
SHM_
LIBRARIES
}
"
)
set
(
CMAKE_REQUIRED_LIBRARIES
"
${
STARPU_LIBRARIES
_DEP
}
"
)
unset
(
STARPU_FXT_START_PROFILING_FOUND CACHE
)
check_function_exists
(
starpu_fxt_start_profiling STARPU_FXT_START_PROFILING_FOUND
)
if
(
STARPU_FXT_START_PROFILING_FOUND
)
...
...
@@ -623,7 +630,12 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
# Check if a specific function exist
list
(
APPEND CMAKE_REQUIRED_INCLUDES
"
${
MPI_C_INCLUDE_PATH
}
"
)
list
(
APPEND CMAKE_REQUIRED_FLAGS
"
${
MPI_C_LINK_FLAGS
}
"
)
set
(
CMAKE_REQUIRED_LIBRARIES
"
${
STARPU_MPI_LIBRARIES
}
-lmpi"
)
set
(
CMAKE_REQUIRED_LIBRARIES
"
${
STARPU_LIBRARIES_DEP
}
"
)
# if (CHAMELEON_SIMULATION)
# set(CMAKE_REQUIRED_LIBRARIES "${STARPU_LIBRARIES_DEP}")
# else()
# set(CMAKE_REQUIRED_LIBRARIES "${STARPU_LIBRARIES_DEP} -lmpi")
# endif()
unset
(
STARPU_MPI_DATA_REGISTER_FOUND CACHE
)
check_function_exists
(
starpu_mpi_data_register_comm STARPU_MPI_DATA_REGISTER_FOUND
)
if
(
STARPU_MPI_DATA_REGISTER_FOUND
)
...
...
@@ -869,17 +881,10 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
# Save all dependencies (all required links)
set
(
CHAMELEON_DEP -lchameleon
)
if
(
CHAMELEON_SCHED_STARPU
)
if
(
CHAMELEON_USE_MPI
)
list
(
APPEND CHAMELEON_DEP
-lchameleon_starpu
${
STARPU_MPI_LIBRARIES
}
)
else
()
list
(
APPEND CHAMELEON_DEP
-lchameleon_starpu
${
STARPU_SHM_LIBRARIES
}
)
endif
()
list
(
APPEND CHAMELEON_DEP
-lchameleon_starpu
${
STARPU_LIBRARIES_DEP
}
)
elseif
(
CHAMELEON_SCHED_PARSEC
)
list
(
APPEND CHAMELEON_DEP
-lchameleon_parsec
...
...
control/common.h
View file @
143e3551
...
...
@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation.
* All rights reserved.
* @copyright (c) 2012-201
4
Inria. All rights reserved.
* @copyright (c) 2012-201
5
Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
*
**/
...
...
example/basic_zposv/CMakeLists.txt
View file @
143e3551
...
...
@@ -47,17 +47,10 @@ list(APPEND libs_for_examples
)
if
(
CHAMELEON_SCHED_STARPU
)
if
(
CHAMELEON_USE_MPI
)
list
(
APPEND libs_for_examples
chameleon_starpu
${
STARPU_MPI_LIBRARIES
}
)
else
()
list
(
APPEND libs_for_examples
chameleon_starpu
${
STARPU_SHM_LIBRARIES
}
)
endif
()
list
(
APPEND libs_for_examples
chameleon_starpu
${
STARPU_LIBRARIES_DEP
}
)
link_directories
(
${
STARPU_LIBRARY_DIRS
}
)
elseif
(
CHAMELEON_SCHED_PARSEC
)
list
(
APPEND libs_for_examples
...
...
example/lapack_to_morse/CMakeLists.txt
View file @
143e3551
...
...
@@ -42,17 +42,10 @@ list(APPEND libs_for_ltm
)
if
(
CHAMELEON_SCHED_STARPU
)
if
(
CHAMELEON_USE_MPI
)
list
(
APPEND libs_for_ltm
chameleon_starpu
${
STARPU_MPI_LIBRARIES
}
)
else
()
list
(
APPEND libs_for_ltm
chameleon_starpu
${
STARPU_SHM_LIBRARIES
}
)
endif
()
list
(
APPEND libs_for_ltm
chameleon_starpu
${
STARPU_LIBRARIES_DEP
}
)
link_directories
(
${
STARPU_LIBRARY_DIRS
}
)
elseif
(
CHAMELEON_SCHED_PARSEC
)
list
(
APPEND libs_for_ltm
...
...
include/morse_simulate.h
View file @
143e3551
...
...
@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation.
* All rights reserved.
* @copyright (c) 2012-201
4
Inria. All rights reserved.
* @copyright (c) 2012-201
5
Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
*
**/
...
...
@@ -28,6 +28,9 @@
/* we need this when starpu is compiled with simgrid enabled */
#if defined(CHAMELEON_SCHED_STARPU) && defined(CHAMELEON_SIMULATION)
#include
<starpu_simgrid_wrap.h>
#if defined(CHAMELEON_USE_MPI)
#define main smpi_simulated_main_
#endif
#endif
#endif
testing/CMakeLists.txt
View file @
143e3551
...
...
@@ -102,17 +102,10 @@ unset(libs_for_tests)
list
(
APPEND libs_for_tests chameleon
)
if
(
CHAMELEON_SCHED_STARPU
)
if
(
CHAMELEON_USE_MPI
)
list
(
APPEND libs_for_tests
chameleon_starpu
${
STARPU_MPI_LIBRARIES
}
)
else
()
list
(
APPEND libs_for_tests
chameleon_starpu
${
STARPU_SHM_LIBRARIES
}
)
endif
()
list
(
APPEND libs_for_tests
chameleon_starpu
${
STARPU_LIBRARIES_DEP
}
)
link_directories
(
${
STARPU_LIBRARY_DIRS
}
)
elseif
(
CHAMELEON_SCHED_PARSEC
)
list
(
APPEND libs_for_tests
...
...
testing/lin/CMakeLists.txt
View file @
143e3551
...
...
@@ -145,7 +145,7 @@ set(libs_for_tests "chameleon")
# TODO: Check for name of following libraries (it certainly changed between morse and new_chameleon)
if
(
MORSE_SCHED_STARPU
)
list
(
APPEND libs_for_tests chameleon_starpu
)
list
(
APPEND libs_for_tests
${
STARPU_LIBRARIES
}
)
list
(
APPEND libs_for_tests
${
STARPU_LIBRARIES
_DEP
}
)
list
(
APPEND libs_for_tests coreblas
)
elseif
(
MORSE_SCHED_QUARK
)
list
(
APPEND libs_for_tests chameleon_starpu
)
...
...
timing/CMakeLists.txt
View file @
143e3551
...
...
@@ -147,17 +147,10 @@ list(APPEND libs_for_timings
)
if
(
CHAMELEON_SCHED_STARPU
)
if
(
CHAMELEON_USE_MPI
)
list
(
APPEND libs_for_timings
chameleon_starpu
${
STARPU_MPI_LIBRARIES
}
)
else
()
list
(
APPEND libs_for_timings
chameleon_starpu
${
STARPU_SHM_LIBRARIES
}
)
endif
()
list
(
APPEND libs_for_timings
chameleon_starpu
${
STARPU_LIBRARIES_DEP
}
)
link_directories
(
${
STARPU_LIBRARY_DIRS
}
)
elseif
(
CHAMELEON_SCHED_PARSEC
)
list
(
APPEND libs_for_timings
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment