Une nouvelle version du portail de gestion des comptes externes sera mise en production lundi 09 août. Elle permettra d'allonger la validité d'un compte externe jusqu'à 3 ans. Pour plus de détails sur cette version consulter : https://doc-si.inria.fr/x/FCeS

Commit 4ef36b8e authored by PRUVOST Florent's avatar PRUVOST Florent
Browse files

Cleaning

parent f7f003e8
Pipeline #249792 passed with stages
in 29 minutes and 28 seconds
......@@ -25,7 +25,6 @@ _extra_blas = [
('', 'sgepdf', 'dgepdf', 'cgepdf', 'zgepdf' ),
('', 'scesca', 'dcesca', 'ccesca', 'zcesca' ),
('', 'sgesum', 'dgesum', 'cgesum', 'zgesum' ),
]
_extra_BLAS = [ [ x.upper() for x in row ] for row in _extra_blas ]
......
......@@ -47,22 +47,22 @@ chameleon_pzcesca_internal( int center,
int tempnn = ( n == (NT-1) ) ? N - n * A->nb : A->nb;
for(m = 0; m < MT; m++) {
int tempmm = ( m == (MT-1) ) ? M - m * A->mb : A->mb;
if ( center == 1 && ( axis == ChamColumnwise || axis == ChamEltwise ) ) {
if ( (center == 1) && ( (axis == ChamColumnwise) || (axis == ChamEltwise) ) ) {
INSERT_TASK_zgesum(
options, ChamColumnwise, tempmm, tempnn,
A(m, n), W( Wgcol, m, n) );
}
if ( center == 1 && ( axis == ChamRowwise || axis == ChamEltwise ) ) {
if ( (center == 1) && ( (axis == ChamRowwise) || (axis == ChamEltwise) ) ) {
INSERT_TASK_zgesum(
options, ChamRowwise, tempmm, tempnn,
A(m, n), W( Wgrow, m, n) );
}
if ( scale == 1 && axis == ChamColumnwise ) {
if ( (scale == 1) && (axis == ChamColumnwise) ) {
INSERT_TASK_dgessq(
options, ChamColumnwise, tempmm, tempnn,
A(m, n), W( Wdcol, m, n) );
}
if ( scale == 1 && axis == ChamRowwise ) {
if ( (scale == 1) && (axis == ChamRowwise) ) {
INSERT_TASK_dgessq(
options, ChamRowwise, tempmm, tempnn,
A(m, n), W( Wdrow, m, n) );
......@@ -73,7 +73,7 @@ chameleon_pzcesca_internal( int center,
for(n = 0; n < NT; n++) {
int tempnn = ( n == (NT-1) ) ? N - n * A->nb : A->nb;
if ( center == 1 && ( axis == ChamColumnwise || axis == ChamEltwise ) ) {
if ( (center == 1) && ( (axis == ChamColumnwise) || (axis == ChamEltwise) ) ) {
/**
* 2) reduce sums of columns between tiles per processus (between lines)
*/
......@@ -101,7 +101,7 @@ chameleon_pzcesca_internal( int center,
}
}
if ( scale == 1 && axis == ChamColumnwise ) {
if ( (scale == 1) && (axis == ChamColumnwise) ) {
/**
* 2) reduce columns (scl,ssq) tiles per processus (between lines)
*/
......@@ -123,13 +123,12 @@ chameleon_pzcesca_internal( int center,
/* 5) deduce the sum square for each column from the pairs (scl,ssq) -> sqrt(sum) = scl*sqrt(ssq) */
INSERT_TASK_dplssq2( options, tempnn, W( Wdcol, 0, n ) );
}
}
for(m = 0; m < MT; m++) {
int tempmm = ( m == (MT-1) ) ? M - m * A->mb : A->mb;
if ( center == 1 && ( axis == ChamRowwise || axis == ChamEltwise ) ) {
if ( (center == 1) && ( (axis == ChamRowwise) || (axis == ChamEltwise) ) ) {
/**
* 2) reduce sums of rows between tiles per processus (between columns)
*/
......@@ -150,7 +149,7 @@ chameleon_pzcesca_internal( int center,
}
}
if ( scale == 1 && axis == ChamRowwise ) {
if ( (scale == 1) && (axis == ChamRowwise) ) {
/**
* 2) reduce rows (scl,ssq) tiles per processus (between lines)
*/
......@@ -172,10 +171,9 @@ chameleon_pzcesca_internal( int center,
/* 5) deduce the sum square for each column from the pairs (scl,ssq) -> sqrt(sum) = scl*sqrt(ssq) */
INSERT_TASK_dplssq2( options, tempmm, W( Wdrow, m, 0 ) );
}
}
if ( center == 1 && axis == ChamEltwise ) {
if ( (center == 1) && (axis == ChamEltwise) ) {
/* 6) reduce global sum on each processus (between columns) */
for(n = Q; n < NT; n++) {
INSERT_TASK_zgeadd(
......
......@@ -30,7 +30,6 @@
* @param[in] A
* The descriptor of the matrix A.
*
*
*******************************************************************************
*
* @retval An allocated opaque pointer to use in CHAMELEON_zcesca_Tile_Async()
......
......@@ -1010,8 +1010,8 @@ TCORE_zunmqr( cham_side_t side,
int
TCORE_zgesum( cham_store_t storev, int M, int N, const CHAM_tile_t *A, CHAM_tile_t *sum )
{
assert( A->format & CHAMELEON_TILE_FULLRANK );
assert( sum->format & CHAMELEON_TILE_FULLRANK );
assert( A->format & (CHAMELEON_TILE_FULLRANK | CHAMELEON_TILE_DESC) );
assert( sum->format & (CHAMELEON_TILE_FULLRANK | CHAMELEON_TILE_DESC) );
return CORE_zgesum( storev, M, N, CHAM_tile_get_ptr( A ), A->ld, CHAM_tile_get_ptr( sum ) );
}
......@@ -1030,12 +1030,12 @@ TCORE_zcesca( int center,
const CHAM_tile_t *Dj,
CHAM_tile_t * A )
{
assert( Gi->format & CHAMELEON_TILE_FULLRANK );
assert( Gj->format & CHAMELEON_TILE_FULLRANK );
assert( G->format & CHAMELEON_TILE_FULLRANK );
assert( Di->format & CHAMELEON_TILE_FULLRANK );
assert( Dj->format & CHAMELEON_TILE_FULLRANK );
assert( A->format & CHAMELEON_TILE_FULLRANK );
assert( Gi->format & (CHAMELEON_TILE_FULLRANK | CHAMELEON_TILE_DESC) );
assert( Gj->format & (CHAMELEON_TILE_FULLRANK | CHAMELEON_TILE_DESC) );
assert( G->format & (CHAMELEON_TILE_FULLRANK | CHAMELEON_TILE_DESC) );
assert( Di->format & (CHAMELEON_TILE_FULLRANK | CHAMELEON_TILE_DESC) );
assert( Dj->format & (CHAMELEON_TILE_FULLRANK | CHAMELEON_TILE_DESC) );
assert( A->format & (CHAMELEON_TILE_FULLRANK | CHAMELEON_TILE_DESC) );
return CORE_zcesca(
center, scale, axis, M, N, Mt, Nt, CHAM_tile_get_ptr( Gi ), Gi->ld, CHAM_tile_get_ptr( Gj ), Gj->ld, CHAM_tile_get_ptr( G ), CHAM_tile_get_ptr( Di ), Di->ld, CHAM_tile_get_ptr( Dj ), Dj->ld, CHAM_tile_get_ptr( A ), A->ld );
}
......
......@@ -18,12 +18,20 @@
#include "chameleon_starpu.h"
#include "runtime_codelet_z.h"
struct cl_zcesca_args_s {
int center;
int scale;
cham_store_t axis;
int m;
int n;
int mt;
int nt;
};
#if !defined(CHAMELEON_SIMULATION)
static void cl_zcesca_cpu_func(void *descr[], void *cl_arg)
{
int center, scale;
cham_store_t axis;
int m, n, mt, nt;
struct cl_zcesca_args_s clargs;
CHAM_tile_t *Gi;
CHAM_tile_t *Gj;
CHAM_tile_t *G;
......@@ -38,8 +46,10 @@ static void cl_zcesca_cpu_func(void *descr[], void *cl_arg)
Dj = cti_interface_get(descr[4]);
A = cti_interface_get(descr[5]);
starpu_codelet_unpack_args( cl_arg, &center, &scale, &axis, &m, &n, &mt, &nt );
TCORE_zcesca( center, scale, axis, m, n, mt, nt, Gi, Gj, G, Di, Dj, A );
starpu_codelet_unpack_args( cl_arg, &clargs );
TCORE_zcesca( clargs.center, clargs.scale, clargs.axis,
clargs.m, clargs.n, clargs.mt, clargs.nt,
Gi, Gj, G, Di, Dj, A );
}
#endif /* !defined(CHAMELEON_SIMULATION) */
......@@ -58,6 +68,15 @@ void INSERT_TASK_zcesca( const RUNTIME_option_t *options,
const CHAM_desc_t *Dj, int Djm, int Djn,
CHAM_desc_t *A, int Am, int An )
{
struct cl_zcesca_args_s clargs = {
.center = center,
.scale = scale,
.axis = axis,
.m = m,
.n = n,
.mt = mt,
.nt = nt
};
struct starpu_codelet *codelet = &cl_zcesca;
void (*callback)(void*) = options->profiling ? cl_zcesca_callback : NULL;
starpu_option_request_t* schedopt = (starpu_option_request_t *)(options->request->schedopt);
......@@ -74,13 +93,7 @@ void INSERT_TASK_zcesca( const RUNTIME_option_t *options,
rt_starpu_insert_task(
codelet,
STARPU_VALUE, &center, sizeof(int),
STARPU_VALUE, &scale, sizeof(int),
STARPU_VALUE, &axis, sizeof(int),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &mt, sizeof(int),
STARPU_VALUE, &nt, sizeof(int),
STARPU_VALUE, &clargs, sizeof(struct cl_zcesca_args_s),
STARPU_R, RTBLKADDR(Gi, CHAMELEON_Complex64_t, Gim, Gin),
STARPU_R, RTBLKADDR(Gj, CHAMELEON_Complex64_t, Gjm, Gjn),
STARPU_R, RTBLKADDR(G, CHAMELEON_Complex64_t, Gm, Gn),
......
......@@ -18,20 +18,24 @@
#include "chameleon_starpu.h"
#include "runtime_codelet_z.h"
#if !defined(CHAMELEON_SIMULATION)
static void cl_zgesum_cpu_func(void *descr[], void *cl_arg)
{
struct cl_zgesum_args_s {
cham_store_t storev;
int m;
int n;
};
#if !defined(CHAMELEON_SIMULATION)
static void cl_zgesum_cpu_func(void *descr[], void *cl_arg)
{
struct cl_zgesum_args_s clargs;
CHAM_tile_t *tileA;
CHAM_tile_t *tileW;
tileA = cti_interface_get(descr[0]);
tileW = cti_interface_get(descr[1]);
starpu_codelet_unpack_args( cl_arg, &storev, &m, &n );
TCORE_zgesum( storev, m, n, tileA, tileW );
starpu_codelet_unpack_args( cl_arg, &clargs );
TCORE_zgesum( clargs.storev, clargs.m, clargs.n, tileA, tileW );
}
#endif /* !defined(CHAMELEON_SIMULATION) */
......@@ -45,6 +49,11 @@ void INSERT_TASK_zgesum( const RUNTIME_option_t *options,
const CHAM_desc_t *A, int Am, int An,
const CHAM_desc_t *SUMS, int SUMSm, int SUMSn )
{
struct cl_zgesum_args_s clargs = {
.storev = storev,
.m = m,
.n = n
};
struct starpu_codelet *codelet = &cl_zgesum;
void (*callback)(void*) = options->profiling ? cl_zgesum_callback : NULL;
starpu_option_request_t* schedopt = (starpu_option_request_t *)(options->request->schedopt);
......@@ -57,9 +66,7 @@ void INSERT_TASK_zgesum( const RUNTIME_option_t *options,
rt_starpu_insert_task(
codelet,
STARPU_VALUE, &storev, sizeof(cham_store_t),
STARPU_VALUE, &m, sizeof(int),
STARPU_VALUE, &n, sizeof(int),
STARPU_VALUE, &clargs, sizeof(struct cl_zgesum_args_s),
STARPU_R, RTBLKADDR(A, CHAMELEON_Complex64_t, Am, An),
STARPU_RW, RTBLKADDR(SUMS, CHAMELEON_Complex64_t, SUMSm, SUMSn),
STARPU_PRIORITY, options->priority,
......
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