Attention une mise à jour du service Gitlab va être effectuée le mardi 18 janvier (et non lundi 17 comme annoncé précédemment) entre 18h00 et 18h30. Cette mise à jour va générer une interruption du service dont nous ne maîtrisons pas complètement la durée mais qui ne devrait pas excéder quelques minutes.

Commit bed75474 authored by Mathieu Faverge's avatar Mathieu Faverge
Browse files

Merge branch 'memaccess' into 'master'

Add macros to make codelets just declare their access and let the macro definition do what should be

See merge request !27
parents 942bd0c2 7d740d57
......@@ -196,6 +196,32 @@ inline static int morse_desc_islocal( const MORSE_desc_t *A, int m, int n )
#endif /* defined(CHAMELEON_USE_MPI) */
}
/*******************************************************************************
* Declare data accesses of codelets using these macros, for instance:
* MORSE_BEGIN_ACCESS_DECLARATION
* MORSE_ACCESS_R(A, Am, An)
* MORSE_ACCESS_R(B, Bm, Bn)
* MORSE_ACCESS_RW(C, Cm, Cn)
* MORSE_END_ACCESS_DECLARATION
*/
#define MORSE_BEGIN_ACCESS_DECLARATION { \
unsigned __morse_need_submit = 0;
#define MORSE_ACCESS_R(A, Am, An) \
if (morse_desc_islocal(A, Am, An)) __morse_need_submit = 1;
#define MORSE_ACCESS_W(A, Am, An) \
if (morse_desc_islocal(A, Am, An)) __morse_need_submit = 1;
#define MORSE_ACCESS_RW(A, Am, An) \
if (morse_desc_islocal(A, Am, An)) __morse_need_submit = 1;
#define MORSE_RANK_CHANGED __morse_need_submit = 1;
#define MORSE_END_ACCESS_DECLARATION \
if (!__morse_need_submit) return; \
}
#ifdef __cplusplus
}
#endif
......
......@@ -78,7 +78,7 @@ void MORSE_TASK_ztpqrt( const MORSE_option_t *options,
sizeof(int), &lda, VALUE,
PASSED_BY_REF, RTBLKADDR( B, MORSE_Complex64_t, Bm, Bn ), INOUT | REGION_FULL,
sizeof(int), &ldb, VALUE,
PASSED_BY_REF, RTBLKADDR( T, MORSE_Complex64_t, Tm, Tn ), INOUT | REGION_FULL,
PASSED_BY_REF, RTBLKADDR( T, MORSE_Complex64_t, Tm, Tn ), OUTPUT | REGION_FULL,
sizeof(int), &ldt, VALUE,
sizeof(MORSE_Complex64_t)*ib*nb, NULL, SCRATCH,
0);
......
......@@ -35,6 +35,12 @@ void MORSE_TASK_dzasum(const MORSE_option_t *options,
{
struct starpu_codelet *codelet = &cl_zasum;
void (*callback)(void*) = options->profiling ? cl_zasum_callback : NULL;
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_R(A, Am, An);
MORSE_ACCESS_RW(B, Bm, Bn);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &storev, sizeof(MORSE_enum),
......
......@@ -33,23 +33,25 @@ void MORSE_TASK_zaxpy(const MORSE_option_t *options,
struct starpu_codelet *codelet = &cl_zaxpy;
void (*callback)(void*) = options->profiling ? cl_zaxpy_callback : NULL;
if ( morse_desc_islocal( A, Am, An ) ||
morse_desc_islocal( B, Bm, Bn ) ){
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &M, sizeof(int),
STARPU_VALUE, alpha, sizeof(MORSE_Complex64_t),
STARPU_R, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &incA, sizeof(int),
STARPU_RW, RTBLKADDR(B, MORSE_Complex64_t, Bm, Bn),
STARPU_VALUE, &incB, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_R(A, Am, An);
MORSE_ACCESS_RW(B, Bm, Bn);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &M, sizeof(int),
STARPU_VALUE, alpha, sizeof(MORSE_Complex64_t),
STARPU_R, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &incA, sizeof(int),
STARPU_RW, RTBLKADDR(B, MORSE_Complex64_t, Bm, Bn),
STARPU_VALUE, &incB, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zaxpy",
STARPU_NAME, "zaxpy",
#endif
0);
}
0);
}
......
......@@ -43,30 +43,30 @@ void MORSE_TASK_zbuild( const MORSE_option_t *options,
void (*callback)(void*) = options->profiling ? cl_zbuild_callback : NULL;
int row_min, row_max, col_min, col_max;
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_W(A, Am, An);
MORSE_END_ACCESS_DECLARATION;
if ( morse_desc_islocal( A, Am, An ) )
{
row_min = Am*A->mb ;
row_max = Am == A->mt-1 ? A->m-1 : row_min+A->mb-1 ;
col_min = An*A->nb ;
col_max = An == A->nt-1 ? A->n-1 : col_min+A->nb-1 ;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &row_min, sizeof(int),
STARPU_VALUE, &row_max, sizeof(int),
STARPU_VALUE, &col_min, sizeof(int),
STARPU_VALUE, &col_max, sizeof(int),
STARPU_W, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_VALUE, &user_data, sizeof(void*),
STARPU_VALUE, &user_build_callback, sizeof(void*),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
row_min = Am*A->mb ;
row_max = Am == A->mt-1 ? A->m-1 : row_min+A->mb-1 ;
col_min = An*A->nb ;
col_max = An == A->nt-1 ? A->n-1 : col_min+A->nb-1 ;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &row_min, sizeof(int),
STARPU_VALUE, &row_max, sizeof(int),
STARPU_VALUE, &col_min, sizeof(int),
STARPU_VALUE, &col_max, sizeof(int),
STARPU_W, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_VALUE, &user_data, sizeof(void*),
STARPU_VALUE, &user_build_callback, sizeof(void*),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zbuild",
STARPU_NAME, "zbuild",
#endif
0);
}
0);
}
......
......@@ -91,27 +91,28 @@ void MORSE_TASK_zgeadd(const MORSE_option_t *options,
struct starpu_codelet *codelet = &cl_zgeadd;
void (*callback)(void*) = options->profiling ? cl_zgeadd_callback : NULL;
if ( morse_desc_islocal( A, Am, An ) ||
morse_desc_islocal( B, Bm, Bn ) )
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &trans, sizeof(MORSE_enum),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &alpha, sizeof(MORSE_Complex64_t),
STARPU_R, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_VALUE, &beta, sizeof(MORSE_Complex64_t),
STARPU_RW, RTBLKADDR(B, MORSE_Complex64_t, Bm, Bn),
STARPU_VALUE, &ldb, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_R(A, Am, An);
MORSE_ACCESS_RW(B, Bm, Bn);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &trans, sizeof(MORSE_enum),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &alpha, sizeof(MORSE_Complex64_t),
STARPU_R, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_VALUE, &beta, sizeof(MORSE_Complex64_t),
STARPU_RW, RTBLKADDR(B, MORSE_Complex64_t, Bm, Bn),
STARPU_VALUE, &ldb, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgeadd",
STARPU_NAME, "zgeadd",
#endif
0);
}
0);
(void)nb;
}
......
......@@ -104,29 +104,30 @@ void MORSE_TASK_zgelqt(const MORSE_option_t *options,
void (*callback)(void*) = options->profiling ? cl_zgelqt_callback : NULL;
MORSE_starpu_ws_t *h_work = (MORSE_starpu_ws_t*)(options->ws_host);
if ( morse_desc_islocal( A, Am, An ) ||
morse_desc_islocal( T, Tm, Tn ) )
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_W, RTBLKADDR(T, MORSE_Complex64_t, Tm, Tn),
STARPU_VALUE, &ldt, sizeof(int),
/* max( nb * (ib+1), ib * (ib+nb) ) */
STARPU_SCRATCH, options->ws_worker,
/* /\* ib*n + 3*ib*ib + max(m,n) *\/ */
STARPU_VALUE, &h_work, sizeof(MORSE_starpu_ws_t *),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_RW(A, Am, An);
MORSE_ACCESS_W(T, Tm, Tn);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_W, RTBLKADDR(T, MORSE_Complex64_t, Tm, Tn),
STARPU_VALUE, &ldt, sizeof(int),
/* max( nb * (ib+1), ib * (ib+nb) ) */
STARPU_SCRATCH, options->ws_worker,
/* /\* ib*n + 3*ib*ib + max(m,n) *\/ */
STARPU_VALUE, &h_work, sizeof(MORSE_starpu_ws_t *),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgelqt",
STARPU_NAME, "zgelqt",
#endif
0);
}
0);
}
......
......@@ -70,37 +70,38 @@ void MORSE_TASK_zgemm(const MORSE_option_t *options,
rank_changed = 1;
}
if ( morse_desc_islocal( A, Am, An ) ||
morse_desc_islocal( B, Bm, Bn ) ||
morse_desc_islocal( C, Cm, Cn ) ||
rank_changed
)
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &transA, sizeof(MORSE_enum),
STARPU_VALUE, &transB, sizeof(MORSE_enum),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &k, sizeof(int),
STARPU_VALUE, &alpha, sizeof(MORSE_Complex64_t),
STARPU_R, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_R, RTBLKADDR(B, MORSE_Complex64_t, Bm, Bn),
STARPU_VALUE, &ldb, sizeof(int),
STARPU_VALUE, &beta, sizeof(MORSE_Complex64_t),
STARPU_RW, RTBLKADDR(C, MORSE_Complex64_t, Cm, Cn),
STARPU_VALUE, &ldc, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_R(A, Am, An);
MORSE_ACCESS_R(B, Bm, Bn);
MORSE_ACCESS_RW(C, Cm, Cn);
if (rank_changed)
MORSE_RANK_CHANGED;
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &transA, sizeof(MORSE_enum),
STARPU_VALUE, &transB, sizeof(MORSE_enum),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &k, sizeof(int),
STARPU_VALUE, &alpha, sizeof(MORSE_Complex64_t),
STARPU_R, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_R, RTBLKADDR(B, MORSE_Complex64_t, Bm, Bn),
STARPU_VALUE, &ldb, sizeof(int),
STARPU_VALUE, &beta, sizeof(MORSE_Complex64_t),
STARPU_RW, RTBLKADDR(C, MORSE_Complex64_t, Cm, Cn),
STARPU_VALUE, &ldc, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_USE_MPI)
STARPU_EXECUTE_ON_NODE, execution_rank,
STARPU_EXECUTE_ON_NODE, execution_rank,
#endif
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgemm",
STARPU_NAME, "zgemm",
#endif
0);
}
0);
}
#if !defined(CHAMELEON_SIMULATION)
......
......@@ -105,29 +105,30 @@ void MORSE_TASK_zgeqrt(const MORSE_option_t *options,
void (*callback)(void*) = options->profiling ? cl_zgeqrt_callback : NULL;
MORSE_starpu_ws_t *h_work = (MORSE_starpu_ws_t*)(options->ws_host);
if ( morse_desc_islocal( A, Am, An ) ||
morse_desc_islocal( T, Tm, Tn ) )
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_W, RTBLKADDR(T, MORSE_Complex64_t, Tm, Tn),
STARPU_VALUE, &ldt, sizeof(int),
/* max( nb * (ib+1), ib * (ib+nb) ) */
STARPU_SCRATCH, options->ws_worker,
/* ib * (m+3*ib) + max(m,n) */
STARPU_VALUE, &h_work, sizeof(MORSE_starpu_ws_t *),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_RW(A, Am, An);
MORSE_ACCESS_W(T, Tm, Tn);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_W, RTBLKADDR(T, MORSE_Complex64_t, Tm, Tn),
STARPU_VALUE, &ldt, sizeof(int),
/* max( nb * (ib+1), ib * (ib+nb) ) */
STARPU_SCRATCH, options->ws_worker,
/* ib * (m+3*ib) + max(m,n) */
STARPU_VALUE, &h_work, sizeof(MORSE_starpu_ws_t *),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgeqrt",
STARPU_NAME, "zgeqrt",
#endif
0);
}
0);
}
......
......@@ -90,30 +90,31 @@ void MORSE_TASK_zgessm(const MORSE_option_t *options,
struct starpu_codelet *codelet = &cl_zgessm;
void (*callback)(void*) = options->profiling ? cl_zgessm_callback : NULL;
if ( morse_desc_islocal( L, Lm, Ln ) ||
morse_desc_islocal( D, Dm, Dn ) ||
morse_desc_islocal( A, Am, An ) )
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &k, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_VALUE, &IPIV, sizeof(int*),
STARPU_R, RTBLKADDR(L, MORSE_Complex64_t, Lm, Ln),
STARPU_VALUE, &ldl, sizeof(int),
STARPU_R, RTBLKADDR(D, MORSE_Complex64_t, Dm, Dn),
STARPU_VALUE, &ldd, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_R(L, Lm, Ln);
MORSE_ACCESS_R(D, Dm, Dn);
MORSE_ACCESS_RW(A, Am, An);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &k, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_VALUE, &IPIV, sizeof(int*),
STARPU_R, RTBLKADDR(L, MORSE_Complex64_t, Lm, Ln),
STARPU_VALUE, &ldl, sizeof(int),
STARPU_R, RTBLKADDR(D, MORSE_Complex64_t, Dm, Dn),
STARPU_VALUE, &ldd, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgessm",
STARPU_NAME, "zgessm",
#endif
0);
}
0);
}
......
......@@ -35,23 +35,24 @@ void MORSE_TASK_zgessq( const MORSE_option_t *options,
struct starpu_codelet *codelet = &cl_zgessq;
void (*callback)(void*) = options->profiling ? cl_zgessq_callback : NULL;
if ( morse_desc_islocal( A, Am, An ) ||
morse_desc_islocal( SCALESUMSQ, SCALESUMSQm, SCALESUMSQn ) )
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_R, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_RW, RTBLKADDR(SCALESUMSQ, double, SCALESUMSQm, SCALESUMSQn),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_R(A, Am, An);
MORSE_ACCESS_RW(SCALESUMSQ, SCALESUMSQm, SCALESUMSQn);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_R, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_RW, RTBLKADDR(SCALESUMSQ, double, SCALESUMSQm, SCALESUMSQn),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgessq",
STARPU_NAME, "zgessq",
#endif
0);
}
0);
}
......
......@@ -40,24 +40,25 @@ void MORSE_TASK_zgetrf(const MORSE_option_t *options,
struct starpu_codelet *codelet = &cl_zgetrf;
void (*callback)(void*) = options->profiling ? cl_zgetrf_callback : NULL;
if ( morse_desc_islocal( A, Am, An ) )
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_VALUE, &IPIV, sizeof(int*),
STARPU_VALUE, &check_info, sizeof(MORSE_bool),
STARPU_VALUE, &iinfo, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_RW(A, Am, An);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_VALUE, &IPIV, sizeof(int*),
STARPU_VALUE, &check_info, sizeof(MORSE_bool),
STARPU_VALUE, &iinfo, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgetrf",
STARPU_NAME, "zgetrf",
#endif
0);
}
0);
}
......
......@@ -100,30 +100,31 @@ void MORSE_TASK_zgetrf_incpiv(const MORSE_option_t *options,
MORSE_starpu_ws_t *h_work = (MORSE_starpu_ws_t*)(options->ws_host);
if ( morse_desc_islocal( A, Am, An ) ||
morse_desc_islocal( L, Lm, Ln ) )
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_W, RTBLKADDR(L, MORSE_Complex64_t, Lm, Ln),
STARPU_VALUE, &ldl, sizeof(int),
STARPU_VALUE, &IPIV, sizeof(int*),
STARPU_VALUE, &check_info, sizeof(MORSE_bool),
STARPU_VALUE, &iinfo, sizeof(int),
STARPU_SCRATCH, options->ws_worker,
STARPU_VALUE, &h_work, sizeof(MORSE_starpu_ws_t *),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_RW(A, Am, An);
MORSE_ACCESS_W(L, Lm, Ln);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_W, RTBLKADDR(L, MORSE_Complex64_t, Lm, Ln),
STARPU_VALUE, &ldl, sizeof(int),
STARPU_VALUE, &IPIV, sizeof(int*),
STARPU_VALUE, &check_info, sizeof(MORSE_bool),
STARPU_VALUE, &iinfo, sizeof(int),
STARPU_SCRATCH, options->ws_worker,
STARPU_VALUE, &h_work, sizeof(MORSE_starpu_ws_t *),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgetrf_incpiv",
STARPU_NAME, "zgetrf_incpiv",
#endif
0);
}
0);
}
......
......@@ -85,23 +85,24 @@ void MORSE_TASK_zgetrf_nopiv(const MORSE_option_t *options,
struct starpu_codelet *codelet = &cl_zgetrf_nopiv;
void (*callback)(void*) = options->profiling ? cl_zgetrf_nopiv_callback : NULL;
if ( morse_desc_islocal( A, Am, An ) )
{
starpu_insert_task(
starpu_mpi_codelet(codelet),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &ib, sizeof(int),
STARPU_RW, RTBLKADDR(A, MORSE_Complex64_t, Am, An),
STARPU_VALUE, &lda, sizeof(int),
STARPU_VALUE, &iinfo, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
MORSE_BEGIN_ACCESS_DECLARATION;