Commit f1d27d3a authored by Mathieu Faverge's avatar Mathieu Faverge

Remove execution_rank as it complexifies the code and should not have been pushed

parent 67f34053
......@@ -41,35 +41,11 @@ void MORSE_TASK_zgemm(const MORSE_option_t *options,
(void)nb;
struct starpu_codelet *codelet = &cl_zgemm;
void (*callback)(void*) = options->profiling ? cl_zgemm_callback : NULL;
int sizeA = lda*k;
int sizeB = ldb*n;
int sizeC = ldc*n;
int execution_rank = C->get_rankof( C, Cm, Cn );
int rank_changed=0;
(void)execution_rank;
/* force execution on the rank owning the largest data (tile) */
int threshold;
char* env = getenv("MORSE_COMM_FACTOR_THRESHOLD");
if (env != NULL)
threshold = (unsigned)atoi(env);
else
threshold = 10;
if ( sizeA > threshold*sizeC ){
execution_rank = A->get_rankof( A, Am, An );
rank_changed = 1;
}else if( sizeB > threshold*sizeC ){
execution_rank = B->get_rankof( B, Bm, Bn );
rank_changed = 1;
}
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(execution_rank);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
......@@ -89,9 +65,6 @@ void MORSE_TASK_zgemm(const MORSE_option_t *options,
STARPU_VALUE, &ldc, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_USE_MPI)
STARPU_EXECUTE_ON_NODE, execution_rank,
#endif
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zgemm",
#endif
......
......@@ -40,29 +40,10 @@ void MORSE_TASK_ztrsm(const MORSE_option_t *options,
(void)nb;
struct starpu_codelet *codelet = &cl_ztrsm;
void (*callback)(void*) = options->profiling ? cl_ztrsm_callback : NULL;
int sizeA = lda*m;
int sizeB = ldb*n;
int execution_rank = B->get_rankof( B, Bm, Bn );
int rank_changed=0;
(void)execution_rank;
/* force execution on the rank owning the largest data (tile) */
int threshold;
char* env = getenv("MORSE_COMM_FACTOR_THRESHOLD");
if (env != NULL)
threshold = (unsigned)atoi(env);
else
threshold = 10;
if ( sizeA > threshold*sizeB ){
execution_rank = A->get_rankof( A, Am, An );
rank_changed=1;
}
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_R(A, Am, An);
MORSE_ACCESS_RW(B, Bm, Bn);
if (rank_changed)
MORSE_RANK_CHANGED(execution_rank);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
......@@ -80,9 +61,6 @@ void MORSE_TASK_ztrsm(const MORSE_option_t *options,
STARPU_VALUE, &ldb, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_USE_MPI)
STARPU_EXECUTE_ON_NODE, execution_rank,
#endif
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "ztrsm",
#endif
......
......@@ -120,34 +120,11 @@ void MORSE_TASK_zunmqr(const MORSE_option_t *options,
{
struct starpu_codelet *codelet = &cl_zunmqr;
void (*callback)(void*) = options->profiling ? cl_zunmqr_callback : NULL;
int sizeA = lda*k;
int sizeT = ldt*n;
int sizeC = ldc*n;
int execution_rank = C->get_rankof( C, Cm, Cn );
int rank_changed=0;
(void)execution_rank;
/* force execution on the rank owning the largest data (tile) */
int threshold;
char* env = getenv("MORSE_COMM_FACTOR_THRESHOLD");
if (env != NULL)
threshold = (unsigned)atoi(env);
else
threshold = 10;
if ( sizeA > threshold*sizeC ){
execution_rank = A->get_rankof( A, Am, An );
rank_changed = 1;
}else if( sizeT > threshold*sizeC ){
execution_rank = T->get_rankof( T, Tm, Tn );
rank_changed = 1;
}
MORSE_BEGIN_ACCESS_DECLARATION;
MORSE_ACCESS_R(A, Am, An);
MORSE_ACCESS_R(T, Tm, Tn);
MORSE_ACCESS_RW(C, Cm, Cn);
if (rank_changed)
MORSE_RANK_CHANGED(execution_rank);
MORSE_END_ACCESS_DECLARATION;
starpu_insert_task(
......@@ -169,9 +146,6 @@ void MORSE_TASK_zunmqr(const MORSE_option_t *options,
STARPU_VALUE, &nb, sizeof(int),
STARPU_PRIORITY, options->priority,
STARPU_CALLBACK, callback,
#if defined(CHAMELEON_USE_MPI)
STARPU_EXECUTE_ON_NODE, execution_rank,
#endif
#if defined(CHAMELEON_CODELETS_HAVE_NAME)
STARPU_NAME, "zunmqr",
#endif
......
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