Commit 7255c7c4 authored by PRUVOST Florent's avatar PRUVOST Florent

Re-work the cmake for simulation mode:

    - use (starpu_cpu_func_t) 1 trick, same as cuda_func
    - cpu funtions are not defined anymore avoiding the dependency to coreblas
    - add #if !defined(CHAMELEON_SIMULATION) where it is needed
    - remove dependency to the coreblas library (become useless)
    - remove useless simucblas, simulapacke libraries
    - remove CHAMELEON_SIMULATION_MAGMA cmake variable and definition
      - keep using CHAMELEON_USE_CUDA and CHAMELEON_USE_MAGMA to consider CUDA kernels
      - this avoid to introduce useless new variables
    - work on messages
parent 73bdfe23
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
# @copyright (c) 2009-2014 The University of Tennessee and The University # @copyright (c) 2009-2014 The University of Tennessee and The University
# of Tennessee Research Foundation. # of Tennessee Research Foundation.
# All rights reserved. # All rights reserved.
# @copyright (c) 2012-2014 Inria. All rights reserved. # @copyright (c) 2012-2016 Inria. All rights reserved.
# @copyright (c) 2012-2016 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. # @copyright (c) 2012-2016 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
# #
### ###
...@@ -235,14 +235,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/") ...@@ -235,14 +235,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
message("-- ${BoldGreen}CHAMELEON_SIMULATION is set to OFF, turn it ON to use" message("-- ${BoldGreen}CHAMELEON_SIMULATION is set to OFF, turn it ON to use"
" SIMULATION mode (only with StarPU compiled with SimGrid)${ColourReset}") " SIMULATION mode (only with StarPU compiled with SimGrid)${ColourReset}")
endif() endif()
option(CHAMELEON_SIMULATION_MAGMA "Enable cuda/magma kernels in simulation mode" OFF)
if (CHAMELEON_SIMULATION_MAGMA)
message("-- ${BoldGreen}CHAMELEON_SIMULATION_MAGMA is set to ON, turn it OFF to disable CUDA/MAGMA kernels in "
" SIMULATION mode${ColourReset}")
else()
message("-- ${BoldGreen}CHAMELEON_SIMULATION_MAGMA is set to OFF, turn it ON to enable CUDA/MAGMA kernels in "
" SIMULATION mode${ColourReset}")
endif()
endif() endif()
# Initially we need to generate files for different precisions # Initially we need to generate files for different precisions
...@@ -554,44 +546,48 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/") ...@@ -554,44 +546,48 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
"\n Note that only POTRF kernels with block sizes of 320 or 960 (simple and double precision) on mirage machine are available for now." "\n Note that only POTRF kernels with block sizes of 320 or 960 (simple and double precision) on mirage machine are available for now."
"\n Database of models is subject to change, it should be enrich in a near future.${ColourReset}") "\n Database of models is subject to change, it should be enrich in a near future.${ColourReset}")
message("-- ${Blue}Add definition CHAMELEON_SIMULATION"
" - Activate simulation mode in Chameleon (to use with StarPU+SimGrid)${ColourReset}")
add_definitions(-DCHAMELEON_SIMULATION)
add_subdirectory(simucore)
# Guard against mis-used simulation mode # Guard against mis-used simulation mode
# if (CHAMELEON_SIMULATION) if(NOT DEFINED CHAMELEON_USE_CUDA)
# if(NOT DEFINED CHAMELEON_SIMULATION_CUDA) message(FATAL_ERROR "${BoldBlue}"
# message(FATAL_ERROR "${BoldBlue}In simulation mode" "In simulation mode CHAMELEON_USE_CUDA and CHAMELEON_USE_MAGMA should be set to"
# "\n CHAMELEON_USE_CUDA and CHAMELEON_USE_MAGMA must be set to" " ensure that the user is aware of the version to be used. If Chameleon's"
# "\n ensure that the user is aware of the version to be used." " kernels are available for NVIDIA CUDA GPUs and if the according"
# "\n If Chameleon's kernels are available for NVIDIA CUDA GPUs and" " perfmodels are available in STARPU_HOME then use CHAMELEON_USE_CUDA=ON"
# "\n if the according perfmodels are available in STARPU_HOME then" " else set CHAMELEON_USE_CUDA=OFF. The same idea is applicable with MAGMA."
# "\n use CHAMELEON_USE_CUDA=ON else set CHAMELEON_USE_CUDA=OFF." "${ColourReset}")
# "\n The same idea is applicable with MAGMA.${ColourReset}") endif()
# endif() if(NOT CHAMELEON_USE_MAGMA)
# if(NOT DEFINED CHAMELEON_SIMULATION_MAGMA) message(WARNING "${BoldBlue}"
# message(FATAL_ERROR "${BoldBlue}In simulation mode" "In simulation mode CHAMELEON_USE_CUDA and CHAMELEON_USE_MAGMA should be set to"
# "\n CHAMELEON_USE_CUDA and CHAMELEON_USE_MAGMA must be set to" " ensure that the user is aware of the version to be used. If Chameleon's"
# "\n ensure that the user is aware of the version to be used." " MAGMA kernels are available for NVIDIA CUDA GPUs and if the according"
# "\n If Chameleon's MAGMA kernels are available for NVIDIA CUDA" " perfmodels are available in STARPU_HOME then use CHAMELEON_USE_MAGMA=ON"
# "\n GPUs and if the according perfmodels are available in" " else set CHAMELEON_USE_MAGMA=OFF.${ColourReset}")
# "\n STARPU_HOME then use CHAMELEON_USE_MAGMA=ON else set" endif()
# "\n CHAMELEON_USE_MAGMA=OFF.${ColourReset}")
# endif()
# endif()
# Add CUDA definition if required
if (CHAMELEON_USE_CUDA)
add_definitions(-DCHAMELEON_USE_CUDA)
# Add MAGMA definition if required
if (CHAMELEON_USE_MAGMA)
add_definitions(-DCHAMELEON_USE_MAGMA)
endif()
endif()
if (NOT CHAMELEON_SCHED_STARPU) if (NOT CHAMELEON_SCHED_STARPU)
message(FATAL_ERROR "Simulation mode of Chameleon only works with" message(FATAL_ERROR "Simulation mode of Chameleon only works with"
"\n the StarPU runtime. Please use CHAMELEON_SCHED_STARPU=ON.") "\n the StarPU runtime. Please use CHAMELEON_SCHED_STARPU=ON.")
endif() endif()
if (CHAMELEON_USE_CUDA) if (CHAMELEON_ENABLE_EXAMPLE)
set(CHAMELEON_USE_CUDA OFF) set(CHAMELEON_ENABLE_EXAMPLE OFF)
message("-- ${BoldBlue}CHAMELEON_USE_CUDA is set to ON but we turn it OFF." message("-- ${BoldBlue}CHAMELEON_ENABLE_EXAMPLE is set to ON but we turn it OFF.")
"\n Because we are compiling the simulation mode (CHAMELEON_SIMULATION=ON),"
"\n we do not need to link with CUDA.${ColourReset}")
endif ()
if (CHAMELEON_USE_MAGMA)
set(CHAMELEON_USE_MAGMA OFF)
message("-- ${BoldBlue}CHAMELEON_USE_MAGMA is set to ON but we turn it OFF."
"\n Because we are compiling the simulation mode (CHAMELEON_SIMULATION=ON),"
"\n we do not need to link with MAGMA.${ColourReset}")
endif () endif ()
if (CHAMELEON_ENABLE_TESTING) if (CHAMELEON_ENABLE_TESTING)
set(CHAMELEON_ENABLE_TESTING OFF) set(CHAMELEON_ENABLE_TESTING OFF)
...@@ -603,7 +599,7 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/") ...@@ -603,7 +599,7 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
# Simulation mode: we depend on SimGrid # Simulation mode: we depend on SimGrid
find_package(SIMGRID REQUIRED) find_package(SIMGRID REQUIRED)
# CHAMELEON depends on MPI # CHAMELEON depends on MPI
#------------------------- #-------------------------
if (CHAMELEON_USE_MPI) if (CHAMELEON_USE_MPI)
...@@ -1014,24 +1010,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/") ...@@ -1014,24 +1010,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
include_directories(${CMAKE_CURRENT_BINARY_DIR}/include) include_directories(${CMAKE_CURRENT_BINARY_DIR}/include)
###############################################################################
# simucore libraries #
######################
if ( CHAMELEON_SIMULATION )
add_subdirectory(simucore)
message("-- ${Blue}Add definition CHAMELEON_SIMULATION"
" - Activate simulation mode in Chameleon (to use with StarPU+SimGrid)${ColourReset}")
add_definitions(-DCHAMELEON_SIMULATION)
endif()
if ( CHAMELEON_SIMULATION_MAGMA )
message("-- ${Blue}Add definition CHAMELEON_SIMULATION_MAGMA"
" - Activate magma kernels in simulation mode${ColourReset}")
add_definitions(-DCHAMELEON_SIMULATION_MAGMA)
endif()
#------------------------------------------------------------------------------
############################################################################### ###############################################################################
# Coreblas library (kernels for CPUs) # # Coreblas library (kernels for CPUs) #
####################################### #######################################
...@@ -1074,7 +1052,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/") ...@@ -1074,7 +1052,6 @@ if (MORSE_DISTRIB_DIR OR EXISTS "${CMAKE_SOURCE_DIR}/cmake_modules/")
enable_testing() enable_testing()
include(CTest) include(CTest)
#enable_testing()
# Necessary to compile executables (temporary) # Necessary to compile executables (temporary)
# should use SystemDetection.cmake module? # should use SystemDetection.cmake module?
......
...@@ -130,7 +130,6 @@ CHAMELEON_ENABLE_TRACING=ON|OFF (default OFF) ...@@ -130,7 +130,6 @@ CHAMELEON_ENABLE_TRACING=ON|OFF (default OFF)
CHAMELEON_SCHED_STARPU=ON|OFF (default ON) CHAMELEON_SCHED_STARPU=ON|OFF (default ON)
CHAMELEON_SCHED_QUARK=ON|OFF (default OFF) CHAMELEON_SCHED_QUARK=ON|OFF (default OFF)
CHAMELEON_SIMULATION=ON|OFF (default OFF) CHAMELEON_SIMULATION=ON|OFF (default OFF)
CHAMELEON_SIMULATION_MAGMA=ON|OFF (default OFF)
Libraries detected with an official cmake module (see module files in CMAKE_ROOT/Modules/): Libraries detected with an official cmake module (see module files in CMAKE_ROOT/Modules/):
CUDA - MPI - Threads CUDA - MPI - Threads
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
# @copyright (c) 2009-2014 The University of Tennessee and The University # @copyright (c) 2009-2014 The University of Tennessee and The University
# of Tennessee Research Foundation. # of Tennessee Research Foundation.
# All rights reserved. # All rights reserved.
# @copyright (c) 2012-2014 Inria. All rights reserved. # @copyright (c) 2012-2016 Inria. All rights reserved.
# @copyright (c) 2012-2014, 2016 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. # @copyright (c) 2012-2014, 2016 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
# #
### ###
...@@ -57,7 +57,6 @@ set(dep_message "${dep_message}" ...@@ -57,7 +57,6 @@ set(dep_message "${dep_message}"
"\n" "\n"
" Trace ...............: ${CHAMELEON_ENABLE_TRACING}\n" " Trace ...............: ${CHAMELEON_ENABLE_TRACING}\n"
" Simulation mode .....: ${CHAMELEON_SIMULATION}\n" " Simulation mode .....: ${CHAMELEON_SIMULATION}\n"
" Magma Simulation mode: ${CHAMELEON_SIMULATION_MAGMA}\n"
"\n" "\n"
" Binaries to build\n" " Binaries to build\n"
" documentation ........: ${CHAMELEON_ENABLE_DOCS}\n" " documentation ........: ${CHAMELEON_ENABLE_DOCS}\n"
...@@ -70,6 +69,7 @@ foreach (_dep ${CHAMELEON_DEP}) ...@@ -70,6 +69,7 @@ foreach (_dep ${CHAMELEON_DEP})
set(dep_message "${dep_message}" set(dep_message "${dep_message}"
" ${_dep}\n") " ${_dep}\n")
endforeach () endforeach ()
string(REGEX REPLACE ";" " " CHAMELEON_DEFINITIONS_LIST "${CHAMELEON_DEFINITIONS_LIST}")
set(dep_message "${dep_message}" set(dep_message "${dep_message}"
"\n" "\n"
" Definitions: ${CHAMELEON_DEFINITIONS_LIST}\n") " Definitions: ${CHAMELEON_DEFINITIONS_LIST}\n")
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
# @copyright (c) 2009-2014 The University of Tennessee and The University # @copyright (c) 2009-2014 The University of Tennessee and The University
# of Tennessee Research Foundation. # of Tennessee Research Foundation.
# All rights reserved. # All rights reserved.
# @copyright (c) 2012-2014 Inria. All rights reserved. # @copyright (c) 2012-2016 Inria. All rights reserved.
# @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. # @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
# #
### ###
...@@ -249,8 +249,6 @@ endif(HAVE_ISO_C_BINDING) ...@@ -249,8 +249,6 @@ endif(HAVE_ISO_C_BINDING)
# Compile step # Compile step
# ------------ # ------------
add_library(chameleon ${CHAMELEON_SRCS} ${CHAMELEON_SRCSF}) add_library(chameleon ${CHAMELEON_SRCS} ${CHAMELEON_SRCSF})
target_link_libraries(chameleon coreblas)
if(CHAMELEON_SCHED_STARPU) if(CHAMELEON_SCHED_STARPU)
target_link_libraries(chameleon chameleon_starpu) target_link_libraries(chameleon chameleon_starpu)
list(INSERT CHAMELEON_DEP 0 -lchameleon_starpu) list(INSERT CHAMELEON_DEP 0 -lchameleon_starpu)
...@@ -261,6 +259,9 @@ elseif(CHAMELEON_SCHED_QUARK) ...@@ -261,6 +259,9 @@ elseif(CHAMELEON_SCHED_QUARK)
target_link_libraries(chameleon chameleon_quark) target_link_libraries(chameleon chameleon_quark)
list(INSERT CHAMELEON_DEP 0 -lchameleon_quark) list(INSERT CHAMELEON_DEP 0 -lchameleon_quark)
endif() endif()
if (NOT CHAMELEON_SIMULATION)
target_link_libraries(chameleon coreblas)
endif()
list(INSERT CHAMELEON_DEP 0 -lchameleon) list(INSERT CHAMELEON_DEP 0 -lchameleon)
add_dependencies(chameleon add_dependencies(chameleon
...@@ -268,6 +269,9 @@ add_dependencies(chameleon ...@@ -268,6 +269,9 @@ add_dependencies(chameleon
coreblas_include coreblas_include
control_include control_include
) )
if (NOT CHAMELEON_SIMULATION)
add_dependencies(chameleon coreblas_include)
endif()
set_property(TARGET chameleon PROPERTY LINKER_LANGUAGE Fortran) set_property(TARGET chameleon PROPERTY LINKER_LANGUAGE Fortran)
set_property(TARGET chameleon PROPERTY Fortran_MODULE_DIRECTORY "${CMAKE_BINARY_DIR}/include") set_property(TARGET chameleon PROPERTY Fortran_MODULE_DIRECTORY "${CMAKE_BINARY_DIR}/include")
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University * @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation. * of Tennessee Research Foundation.
* All rights reserved. * All rights reserved.
* @copyright (c) 2012-2014 Inria. All rights reserved. * @copyright (c) 2012-2016 Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
* *
**/ **/
...@@ -71,7 +71,7 @@ void morse_pzgelqf(MORSE_desc_t *A, MORSE_desc_t *T, ...@@ -71,7 +71,7 @@ void morse_pzgelqf(MORSE_desc_t *A, MORSE_desc_t *T,
ws_worker = A->nb * (ib+1); ws_worker = A->nb * (ib+1);
/* Allocation of temporary (scratch) working space */ /* Allocation of temporary (scratch) working space */
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
/* Worker space /* Worker space
* *
* zgelqt = max( A->nb * (ib+1), ib * (ib + A->nb) ) * zgelqt = max( A->nb * (ib+1), ib * (ib + A->nb) )
...@@ -118,7 +118,7 @@ void morse_pzgelqf(MORSE_desc_t *A, MORSE_desc_t *T, ...@@ -118,7 +118,7 @@ void morse_pzgelqf(MORSE_desc_t *A, MORSE_desc_t *T,
MorseUpper, A->mb, A->nb, A->nb, MorseUpper, A->mb, A->nb, A->nb,
A(k, k), ldak, A(k, k), ldak,
DIAG(k), ldak ); DIAG(k), ldak );
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
MORSE_TASK_zlaset( MORSE_TASK_zlaset(
&options, &options,
MorseLower, A->mb, A->nb, MorseLower, A->mb, A->nb,
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University * @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation. * of Tennessee Research Foundation.
* All rights reserved. * All rights reserved.
* @copyright (c) 2012-2014 Inria. All rights reserved. * @copyright (c) 2012-2016 Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
* *
**/ **/
...@@ -79,7 +79,7 @@ void morse_pzgelqfrh(MORSE_desc_t *A, MORSE_desc_t *T, int BS, ...@@ -79,7 +79,7 @@ void morse_pzgelqfrh(MORSE_desc_t *A, MORSE_desc_t *T, int BS,
ws_worker = A->nb * (ib+1); ws_worker = A->nb * (ib+1);
/* Allocation of temporary (scratch) working space */ /* Allocation of temporary (scratch) working space */
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
/* Worker space /* Worker space
* *
* zgelqt = max( A->nb * (ib+1), ib * (ib + A->nb) ) * zgelqt = max( A->nb * (ib+1), ib * (ib + A->nb) )
...@@ -129,7 +129,7 @@ void morse_pzgelqfrh(MORSE_desc_t *A, MORSE_desc_t *T, int BS, ...@@ -129,7 +129,7 @@ void morse_pzgelqfrh(MORSE_desc_t *A, MORSE_desc_t *T, int BS,
MorseUpper, tempkm, tempNn, A->nb, MorseUpper, tempkm, tempNn, A->nb,
A(k, N), ldak, A(k, N), ldak,
DIAG(k, N), ldak ); DIAG(k, N), ldak );
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
MORSE_TASK_zlaset( MORSE_TASK_zlaset(
&options, &options,
MorseLower, tempkm, tempNn, MorseLower, tempkm, tempNn,
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University * @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation. * of Tennessee Research Foundation.
* All rights reserved. * All rights reserved.
* @copyright (c) 2012-2014 Inria. All rights reserved. * @copyright (c) 2012-2016 Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
* *
**/ **/
...@@ -72,7 +72,7 @@ void morse_pzgeqrf(MORSE_desc_t *A, MORSE_desc_t *T, ...@@ -72,7 +72,7 @@ void morse_pzgeqrf(MORSE_desc_t *A, MORSE_desc_t *T,
ws_worker = A->nb * (ib+1); ws_worker = A->nb * (ib+1);
/* Allocation of temporary (scratch) working space */ /* Allocation of temporary (scratch) working space */
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
/* Worker space /* Worker space
* *
* zgeqrt = max( A->nb * (ib+1), ib * (ib + A->nb) ) * zgeqrt = max( A->nb * (ib+1), ib * (ib + A->nb) )
...@@ -119,7 +119,7 @@ void morse_pzgeqrf(MORSE_desc_t *A, MORSE_desc_t *T, ...@@ -119,7 +119,7 @@ void morse_pzgeqrf(MORSE_desc_t *A, MORSE_desc_t *T,
MorseLower, A->mb, A->nb, A->nb, MorseLower, A->mb, A->nb, A->nb,
A(k, k), ldak, A(k, k), ldak,
DIAG(k), ldak ); DIAG(k), ldak );
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
MORSE_TASK_zlaset( MORSE_TASK_zlaset(
&options, &options,
MorseUpper, A->mb, A->nb, MorseUpper, A->mb, A->nb,
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University * @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation. * of Tennessee Research Foundation.
* All rights reserved. * All rights reserved.
* @copyright (c) 2012-2014 Inria. All rights reserved. * @copyright (c) 2012-2016 Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
* *
**/ **/
...@@ -77,7 +77,7 @@ void morse_pzgeqrfrh(MORSE_desc_t *A, MORSE_desc_t *T, int BS, ...@@ -77,7 +77,7 @@ void morse_pzgeqrfrh(MORSE_desc_t *A, MORSE_desc_t *T, int BS,
ws_worker = A->nb * (ib+1); ws_worker = A->nb * (ib+1);
/* Allocation of temporary (scratch) working space */ /* Allocation of temporary (scratch) working space */
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
/* Worker space /* Worker space
* *
* zgeqrt = max( A->nb * (ib+1), ib * (ib + A->nb) ) * zgeqrt = max( A->nb * (ib+1), ib * (ib + A->nb) )
...@@ -130,7 +130,7 @@ void morse_pzgeqrfrh(MORSE_desc_t *A, MORSE_desc_t *T, int BS, ...@@ -130,7 +130,7 @@ void morse_pzgeqrfrh(MORSE_desc_t *A, MORSE_desc_t *T, int BS,
MorseLower, tempMm, A->nb, A->nb, MorseLower, tempMm, A->nb, A->nb,
A(M, k), ldaM, A(M, k), ldaM,
DIAG(M, k), ldaM ); DIAG(M, k), ldaM );
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
MORSE_TASK_zlaset( MORSE_TASK_zlaset(
&options, &options,
MorseUpper, tempMm, A->nb, MorseUpper, tempMm, A->nb,
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University * @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation. * of Tennessee Research Foundation.
* All rights reserved. * All rights reserved.
* @copyright (c) 2012-2014 Inria. All rights reserved. * @copyright (c) 2012-2016 Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
* *
**/ **/
...@@ -64,7 +64,7 @@ void morse_pzgetrf_incpiv(MORSE_desc_t *A, MORSE_desc_t *L, int *IPIV, ...@@ -64,7 +64,7 @@ void morse_pzgetrf_incpiv(MORSE_desc_t *A, MORSE_desc_t *L, int *IPIV,
RUNTIME_options_init(&options, morse, sequence, request); RUNTIME_options_init(&options, morse, sequence, request);
ib = MORSE_IB; ib = MORSE_IB;
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
h_work_size = sizeof(MORSE_Complex64_t)*( 2*ib + 2*L->nb )*2*A->mb; h_work_size = sizeof(MORSE_Complex64_t)*( 2*ib + 2*L->nb )*2*A->mb;
d_work_size = sizeof(MORSE_Complex64_t)*( ib )*2*A->mb; d_work_size = sizeof(MORSE_Complex64_t)*( ib )*2*A->mb;
#else #else
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University * @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation. * of Tennessee Research Foundation.
* All rights reserved. * All rights reserved.
* @copyright (c) 2012-2014 Inria. All rights reserved. * @copyright (c) 2012-2016 Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
* *
**/ **/
...@@ -77,7 +77,7 @@ void morse_pzunglq(MORSE_desc_t *A, MORSE_desc_t *Q, MORSE_desc_t *T, ...@@ -77,7 +77,7 @@ void morse_pzunglq(MORSE_desc_t *A, MORSE_desc_t *Q, MORSE_desc_t *T,
ws_worker = A->nb * ib; ws_worker = A->nb * ib;
/* Allocation of temporary (scratch) working space */ /* Allocation of temporary (scratch) working space */
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
/* Worker space /* Worker space
* *
* zunmlq = A->nb * ib * zunmlq = A->nb * ib
...@@ -124,7 +124,7 @@ void morse_pzunglq(MORSE_desc_t *A, MORSE_desc_t *Q, MORSE_desc_t *T, ...@@ -124,7 +124,7 @@ void morse_pzunglq(MORSE_desc_t *A, MORSE_desc_t *Q, MORSE_desc_t *T,
MorseUpper, tempkmin, tempkn, A->nb, MorseUpper, tempkmin, tempkn, A->nb,
A(k, k), ldak, A(k, k), ldak,
DIAG(k), ldak ); DIAG(k), ldak );
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
MORSE_TASK_zlaset( MORSE_TASK_zlaset(
&options, &options,
MorseLower, tempkmin, tempkn, MorseLower, tempkmin, tempkn,
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University * @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation. * of Tennessee Research Foundation.
* All rights reserved. * All rights reserved.
* @copyright (c) 2012-2014 Inria. All rights reserved. * @copyright (c) 2012-2016 Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
* *
**/ **/
...@@ -75,7 +75,7 @@ void morse_pzunglqrh(MORSE_desc_t *A, MORSE_desc_t *Q, ...@@ -75,7 +75,7 @@ void morse_pzunglqrh(MORSE_desc_t *A, MORSE_desc_t *Q,
*/ */
ws_worker = A->nb * ib; ws_worker = A->nb * ib;
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
/* Worker space /* Worker space
* *
* zunmqr = A->nb * ib * zunmqr = A->nb * ib
...@@ -147,7 +147,7 @@ void morse_pzunglqrh(MORSE_desc_t *A, MORSE_desc_t *Q, ...@@ -147,7 +147,7 @@ void morse_pzunglqrh(MORSE_desc_t *A, MORSE_desc_t *Q,
MorseUpper, tempkmin, tempNn, A->nb, MorseUpper, tempkmin, tempNn, A->nb,
A(k, N), ldak, A(k, N), ldak,
DIAG(k, N), ldak ); DIAG(k, N), ldak );
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
MORSE_TASK_zlaset( MORSE_TASK_zlaset(
&options, &options,
MorseLower, tempkmin, tempNn, MorseLower, tempkmin, tempNn,
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @copyright (c) 2009-2014 The University of Tennessee and The University * @copyright (c) 2009-2014 The University of Tennessee and The University
* of Tennessee Research Foundation. * of Tennessee Research Foundation.
* All rights reserved. * All rights reserved.
* @copyright (c) 2012-2014 Inria. All rights reserved. * @copyright (c) 2012-2016 Inria. All rights reserved.
* @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved. * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
* *
**/ **/
...@@ -77,7 +77,7 @@ void morse_pzungqr(MORSE_desc_t *A, MORSE_desc_t *Q, MORSE_desc_t *T, ...@@ -77,7 +77,7 @@ void morse_pzungqr(MORSE_desc_t *A, MORSE_desc_t *Q, MORSE_desc_t *T,
ws_worker = A->nb * ib; ws_worker = A->nb * ib;
/* Allocation of temporary (scratch) working space */ /* Allocation of temporary (scratch) working space */
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
/* Worker space /* Worker space
* *
* zunmqr = A->nb * ib * zunmqr = A->nb * ib
...@@ -126,7 +126,7 @@ void morse_pzungqr(MORSE_desc_t *A, MORSE_desc_t *Q, MORSE_desc_t *T, ...@@ -126,7 +126,7 @@ void morse_pzungqr(MORSE_desc_t *A, MORSE_desc_t *Q, MORSE_desc_t *T,
MorseLower, tempkm, tempkmin, A->nb, MorseLower, tempkm, tempkmin, A->nb,
A(k, k), ldak, A(k, k), ldak,
DIAG(k), ldak ); DIAG(k), ldak );
#if defined(CHAMELEON_USE_MAGMA) || defined(CHAMELEON_SIMULATION_MAGMA) #if defined(CHAMELEON_USE_MAGMA)
MORSE_TASK_zlaset( MORSE_TASK_zlaset(
&options, &options,
MorseUpper, tempkm, tempkmin, MorseUpper, tempkm, tempkmin,
......