Commit 8c845af7 authored by Mathieu Faverge's avatar Mathieu Faverge

Fix a large bunch of warnings, and there are still mistakes that should be...

Fix a large bunch of warnings, and there are still mistakes that should be fixed before the SC release
parent 190689fd
......@@ -50,13 +50,11 @@ void morse_pzlange(MORSE_enum norm, MORSE_desc_t *A, double *result,
MORSE_desc_t *RESULT = NULL;
MORSE_context_t *morse;
MORSE_option_t options;
size_t h_work_size, d_work_size;
int workm, workn;
int tempkm, tempkn;
int ldam;
int m, n, k;
double alpha = 1.0;
int m, n;
morse = morse_context_self();
if (sequence->status != MORSE_SUCCESS)
......
......@@ -50,16 +50,15 @@ void morse_pzlanhe(MORSE_enum norm, MORSE_enum uplo, MORSE_desc_t *A, double *re
MORSE_desc_t *RESULT = NULL;
MORSE_context_t *morse;
MORSE_option_t options;
size_t h_work_size, d_work_size;
int workm, workn;
int tempkm, tempkn;
int ldam;
int m, n, k;
int part_p, part_q;
int m, n;
/* int part_p, part_q; */
part_p = A->myrank / A->q;
part_q = A->myrank % A->q;
/* part_p = A->myrank / A->q; */
/* part_q = A->myrank % A->q; */
morse = morse_context_self();
if (sequence->status != MORSE_SUCCESS)
......
......@@ -50,16 +50,15 @@ void morse_pzlansy(MORSE_enum norm, MORSE_enum uplo, MORSE_desc_t *A, double *re
MORSE_desc_t *RESULT = NULL;
MORSE_context_t *morse;
MORSE_option_t options;
size_t h_work_size, d_work_size;
int workm, workn;
int tempkm, tempkn;
int ldam;
int m, n, k;
int part_p, part_q;
int m, n;
/* int part_p, part_q; */
part_p = A->myrank / A->q;
part_q = A->myrank % A->q;
/* part_p = A->myrank / A->q; */
/* part_q = A->myrank % A->q; */
morse = morse_context_self();
if (sequence->status != MORSE_SUCCESS)
......
......@@ -44,18 +44,17 @@ void morse_pzlantr(MORSE_enum norm, MORSE_enum uplo, MORSE_enum diag,
MORSE_desc_t *RESULT = NULL;
MORSE_context_t *morse;
MORSE_option_t options;
size_t h_work_size, d_work_size;
int workm, workn;
int tempkm, tempkn;
int ldam, ldan;
int m, n, k, minMNT;
int part_p, part_q;
int m, n, minMNT;
/* int part_p, part_q; */
minMNT = min( A->mt, A->nt );
part_p = A->myrank / A->q;
part_q = A->myrank % A->q;
/* part_p = A->myrank / A->q; */
/* part_q = A->myrank % A->q; */
morse = morse_context_self();
if (sequence->status != MORSE_SUCCESS)
......
......@@ -37,13 +37,13 @@
* Parallel tile Cholesky factorization - dynamic scheduling
**/
void morse_pzpotrimm(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_desc_t *C,
MORSE_sequence_t *sequence, MORSE_request_t *request)
MORSE_sequence_t *sequence, MORSE_request_t *request)
{
MORSE_context_t *morse;
MORSE_option_t options;
int k, m, n;
int lda, ldab, ldb, ldc;
int lda, ldb, ldc;
int ldak, ldam, ldan;
int tempkm, tempmm, tempnn, tempkn;
......@@ -73,14 +73,14 @@ void morse_pzpotrimm(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_de
/*
* ZPOTRF
*/
for (k = 0; k < A->mt; k++) {
tempkm = k == A->mt-1 ? A->m-k*A->mb : A->mb;
ldak = BLKLDD(A, k);
MORSE_TASK_zpotrf(
&options,
MorseLower, tempkm, A->mb,
for (k = 0; k < A->mt; k++) {
tempkm = k == A->mt-1 ? A->m-k*A->mb : A->mb;
ldak = BLKLDD(A, k);
MORSE_TASK_zpotrf(
&options,
MorseLower, tempkm, A->mb,
A(k, k), ldak, A->nb*k);
for (m = k+1; m < A->mt; m++) {
tempmm = m == A->mt-1 ? A->m-m*A->mb : A->mb;
ldam = BLKLDD(A, m);
......@@ -93,30 +93,30 @@ void morse_pzpotrimm(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_de
}
MORSE_TASK_dataflush( &options, A(k, k) );
for (n = k+1; n < A->nt; n++) {
tempnn = n == A->nt-1 ? A->n-n*A->nb : A->nb;
ldan = BLKLDD(A, n);
MORSE_TASK_zherk(
&options,
MorseLower, MorseNoTrans,
tempnn, A->nb, A->mb,
-1.0, A(n, k), ldan,
1.0, A(n, n), ldan);
for (m = n+1; m < A->mt; m++) {
tempmm = m == A->mt-1 ? A->m - m*A->mb : A->mb;
ldam = BLKLDD(A, m);
MORSE_TASK_zgemm(
&options,
MorseNoTrans, MorseConjTrans,
tempmm, tempnn, A->mb, A->mb,
mzone, A(m, k), ldam,
A(n, k), ldan,
zone, A(m, n), ldam);
}
MORSE_TASK_dataflush( &options, A(n, k) );
}
}
for (n = k+1; n < A->nt; n++) {
tempnn = n == A->nt-1 ? A->n-n*A->nb : A->nb;
ldan = BLKLDD(A, n);
MORSE_TASK_zherk(
&options,
MorseLower, MorseNoTrans,
tempnn, A->nb, A->mb,
-1.0, A(n, k), ldan,
1.0, A(n, n), ldan);
for (m = n+1; m < A->mt; m++) {
tempmm = m == A->mt-1 ? A->m - m*A->mb : A->mb;
ldam = BLKLDD(A, m);
MORSE_TASK_zgemm(
&options,
MorseNoTrans, MorseConjTrans,
tempmm, tempnn, A->mb, A->mb,
mzone, A(m, k), ldam,
A(n, k), ldan,
zone, A(m, n), ldam);
}
MORSE_TASK_dataflush( &options, A(n, k) );
}
}
/*
* ZTRTRI
*/
......@@ -273,37 +273,37 @@ void morse_pzpotrimm(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_de
MorseLeft, MorseUpper, MorseConjTrans, MorseNonUnit,
A->mb, tempnn, A->mb,
zone, A(k, k), ldak,
A(k, n), ldak);
A(k, n), ldak);
}
MORSE_TASK_dataflush( &options, A(k, k) );
for (m = k+1; m < A->mt; m++) {
tempmm = m == A->mt-1 ? A->m - m*A->mb : A->mb;
ldam = BLKLDD(A, m);
for (m = k+1; m < A->mt; m++) {
tempmm = m == A->mt-1 ? A->m - m*A->mb : A->mb;
ldam = BLKLDD(A, m);
MORSE_TASK_zherk(
&options,
MorseUpper, MorseConjTrans,
tempmm, A->mb, A->mb,
-1.0, A(k, m), ldak,
1.0, A(m, m), ldam);
1.0, A(m, m), ldam);
for (n = m+1; n < A->nt; n++) {
tempnn = n == A->nt-1 ? A->n-n*A->nb : A->nb;
for (n = m+1; n < A->nt; n++) {
tempnn = n == A->nt-1 ? A->n-n*A->nb : A->nb;
MORSE_TASK_zgemm(
&options,
MorseConjTrans, MorseNoTrans,
tempmm, tempnn, A->mb, A->mb,
mzone, A(k, m), ldak,
A(k, n), ldak,
A(k, n), ldak,
zone, A(m, n), ldam);
}
MORSE_TASK_dataflush( &options, A(k, m) );
}
}
}
MORSE_TASK_dataflush( &options, A(k, m) );
}
}
/*
* ZTRTRI
*/
......
......@@ -219,7 +219,7 @@ int MORSE_zpotrimm_Tile(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE
MORSE_zpotrimm_Tile_Async(uplo, A, B, C, sequence, &request);
RUNTIME_barrier(morse);
RUNTIME_desc_getoncpu(C);
status = sequence->status;
morse_sequence_destroy(morse, sequence);
return status;
......@@ -315,7 +315,7 @@ int MORSE_zpotrimm_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B,
return MORSE_SUCCESS;
*/
morse_pzpotrimm(uplo, A, B, C, sequence, request);
/*
morse_pztrtri(uplo, MorseNonUnit, A, sequence, request);
......
......@@ -171,7 +171,7 @@ int MORSE_zsysv(MORSE_enum uplo, int N, int NRHS,
/* morse_ziptile2lap( descB, B, NB, NB, LDB, NRHS, sequence, &request);*/
/* RUNTIME_barrier(morse);*/
/* }*/
status = sequence->status;
morse_sequence_destroy(morse, sequence);
return status;
......@@ -238,7 +238,7 @@ int MORSE_zsysv_Tile(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B)
RUNTIME_barrier(morse);
RUNTIME_desc_getoncpu(A);
RUNTIME_desc_getoncpu(B);
status = sequence->status;
morse_sequence_destroy(morse, sequence);
return status;
......
......@@ -100,6 +100,7 @@ void morse_pzgerbh(MORSE_desc_t *A, MORSE_desc_t *T, MORSE_sequence_t *sequence,
void morse_pzgerbbrh(MORSE_desc_t *A, MORSE_desc_t *T, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzgetmi2(MORSE_enum idep, MORSE_enum odep, MORSE_enum storev, int m, int n, int mb, int nb, MORSE_Complex64_t *A, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzgetrf_incpiv(MORSE_desc_t *A, MORSE_desc_t *L, int *IPIV, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzgetrf_nopiv(MORSE_desc_t *A, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzgetrf_reclap(MORSE_desc_t *A, int *IPIV, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzgetrf_rectil(MORSE_desc_t *A, int *IPIV, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzhbcpy_t2bl(MORSE_enum uplo, MORSE_desc_t *A, MORSE_Complex64_t *AB, int LDAB, MORSE_sequence_t *sequence, MORSE_request_t *request);
......@@ -127,10 +128,12 @@ void morse_pzplghe(double bump, MORSE_desc_t *A, unsigned long long int seed, MO
void morse_pzplgsy(MORSE_Complex64_t bump, MORSE_desc_t *A, unsigned long long int seed, MORSE_sequence_t *sequence, MORSE_request_t *request );
void morse_pzplrnt(MORSE_desc_t *A, unsigned long long int seed, MORSE_sequence_t *sequence, MORSE_request_t *request );
void morse_pzpotrf(MORSE_enum uplo, MORSE_desc_t *A, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzpotrimm(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_desc_t *C, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzshift(int, int, int, MORSE_Complex64_t *, int *, int, int, int, MORSE_sequence_t*, MORSE_request_t*);
void morse_pzsymm(MORSE_enum side, MORSE_enum uplo, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_Complex64_t beta, MORSE_desc_t *C, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzsyrk(MORSE_enum uplo, MORSE_enum trans, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_Complex64_t beta, MORSE_desc_t *C, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzsyr2k(MORSE_enum uplo, MORSE_enum trans, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_Complex64_t beta, MORSE_desc_t *C, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pzsytrf(MORSE_enum uplo, MORSE_desc_t *A, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pztrmm(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pztrsm(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_sequence_t *sequence, MORSE_request_t *request);
void morse_pztrsmpl(MORSE_desc_t *A, MORSE_desc_t *B, MORSE_desc_t *L, int *IPIV, MORSE_sequence_t *sequence, MORSE_request_t *request);
......
......@@ -29,16 +29,15 @@
#include "coreblas/include/lapacke.h"
#include "coreblas/include/coreblas.h"
/***************************************************************************//**
/**
***************************************************************************
*
* @ingroup CORE_MORSE_Complex64_t
*
* CORE_zgesplit splits a matrix A into two parts (Upper/Lower),
* A keeps its lower/upper part unchanged and the other part is filled with zeros .
* ones can be optionally set on the diagonal.
* The part of A which is erased is copied in B.
*
*
* CORE_zgesplit splits a matrix A into two parts (Upper/Lower), A keeps its
* lower/upper part unchanged and the other part is filled with zeros. Ones
* can be optionally set on the diagonal. The part of A which is erased is
* copied in B.
*
*******************************************************************************
*
......@@ -73,9 +72,7 @@ int CORE_zgesplit(MORSE_enum side, MORSE_enum diag,
MORSE_Complex64_t *A, int LDA,
MORSE_Complex64_t *B, int LDB)
{
MORSE_enum uplo;
int i, j;
MORSE_enum uplo;
if (M < 0) {
coreblas_error(1, "Illegal value of M");
......@@ -95,9 +92,9 @@ int CORE_zgesplit(MORSE_enum side, MORSE_enum diag,
}
if (side == MorseLeft){
uplo = MorseUpper;
uplo = MorseUpper;
} else{
uplo = MorseLower;
uplo = MorseLower;
}
LAPACKE_zlacpy_work(LAPACK_COL_MAJOR,
......@@ -110,6 +107,3 @@ int CORE_zgesplit(MORSE_enum side, MORSE_enum diag,
return MORSE_SUCCESS;
}
......@@ -273,6 +273,9 @@ void CORE_zswpab(int i, int n1, int n2,
MORSE_Complex64_t *A, MORSE_Complex64_t *work);
int CORE_zswptr_ontile(MORSE_desc_t descA, int i1, int i2, const int *ipiv, int inc,
const MORSE_Complex64_t *Akk, int ldak);
void CORE_ztrasm(MORSE_enum storev, MORSE_enum uplo, MORSE_enum diag,
int M, int N,
const MORSE_Complex64_t *A, int lda, double *work);
void CORE_ztrdalg(MORSE_enum uplo, int N, int NB,
const MORSE_desc_t *pA, MORSE_Complex64_t *V, MORSE_Complex64_t *TAU,
int i, int j, int m, int grsiz);
......@@ -286,6 +289,9 @@ void CORE_ztrsm(MORSE_enum side, MORSE_enum uplo,
int M, int N,
MORSE_Complex64_t alpha, const MORSE_Complex64_t *A, int LDA,
MORSE_Complex64_t *B, int LDB);
int CORE_ztrssq(MORSE_enum uplo, MORSE_enum diag, int M, int N,
const MORSE_Complex64_t *A, int LDA,
double *scale, double *sumsq);
void CORE_ztrtri(MORSE_enum uplo, MORSE_enum diag, int N,
MORSE_Complex64_t *A, int LDA, int *info);
int CORE_ztslqt(int M, int N, int IB,
......
......@@ -29,7 +29,7 @@
* Function that allocate an array of pointers to square tiles (allocated to 0)
**/
MORSE_Complex64_t **allocate_tile_matrix(int m, int n, int nb){
int i, j;
int i;
int mt, nt;
MORSE_Complex64_t **mat;
......
......@@ -23,6 +23,7 @@
**/
#include "step0.h"
#include <coreblas/include/coreblas.h>
/*
* @brief step0 is a simple Cholesky example using the C interface of
......@@ -37,8 +38,6 @@
* The precision is: double
*/
int main(int argc, char *argv[]) {
size_t i, j;
size_t N; // matrix order
size_t NRHS; // number of RHS vectors
......
......@@ -45,7 +45,6 @@
*/
int main(int argc, char *argv[]) {
size_t i, j;
size_t N; // matrix order
size_t NRHS; // number of RHS vectors
int NCPU; // number of cores to use
......
......@@ -36,7 +36,6 @@
*/
int main(int argc, char *argv[]) {
size_t i, j;
size_t N; // matrix order
int NB; // number of rows and columns in tiles
int NRHS; // number of RHS vectors
......
......@@ -34,7 +34,6 @@
*/
int main(int argc, char *argv[]) {
size_t i, j;
size_t N; // matrix order
int NB; // number of rows and columns in tiles
int NRHS; // number of RHS vectors
......
......@@ -129,7 +129,7 @@ static void print_header(char *prog_name, int * iparam) {
* Function that allocate an array of pointers to square tiles (allocated to 0)
*/
double **allocate_tile_matrix(int m, int n, int nb){
int i, j;
int i;
int mt, nt;
double **mat;
......@@ -155,7 +155,7 @@ double **allocate_tile_matrix(int m, int n, int nb){
* Function that deallocate an array of pointers to square tiles
*/
static void deallocate_tile_matrix(double **mat, int m, int n, int nb){
int i, j;
int i;
int mt, nt;
/* compute number of tiles in rows and columns */
......
......@@ -38,7 +38,6 @@
*/
int main(int argc, char *argv[]) {
size_t i, j;
size_t N; // matrix order
int NB; // number of rows and columns in tiles
int NRHS; // number of RHS vectors
......@@ -152,6 +151,10 @@ int main(int argc, char *argv[]) {
RUNTIME_desc_getoncpu(descX);
status = sequence->status;
if ( status != 0 ) {
fprintf(stderr, "Error in computation (%d)\n", status);
return EXIT_FAILURE;
}
MORSE_Sequence_Destroy(sequence);
cpu_time += cWtime();
......
......@@ -38,7 +38,6 @@
*/
int main(int argc, char *argv[]) {
size_t i, j;
size_t N; // matrix order
int NB; // number of rows and columns in tiles
int NRHS; // number of RHS vectors
......@@ -156,6 +155,10 @@ int main(int argc, char *argv[]) {
RUNTIME_desc_getoncpu(descX);
status = sequence->status;
if ( status != 0 ) {
fprintf(stderr, "Error in computation (%d)\n", status);
return EXIT_FAILURE;
}
MORSE_Sequence_Destroy(sequence);
cpu_time += cWtime();
......
......@@ -36,7 +36,6 @@
*/
int main(int argc, char *argv[]) {
size_t i, j;
size_t N; // matrix order
int NB; // number of rows and columns in tiles
int NRHS; // number of RHS vectors
......@@ -178,6 +177,10 @@ int main(int argc, char *argv[]) {
RUNTIME_desc_getoncpu(descX);
status = sequence->status;
if ( status != 0 ) {
fprintf(stderr, "Error in computation (%d)\n", status);
return EXIT_FAILURE;
}
MORSE_Sequence_Destroy(sequence);
cpu_time += cWtime();
......
......@@ -93,13 +93,13 @@ int MORSE_zposv(MORSE_enum uplo, int N, int NRHS, MORSE_Complex64_t *A, int LDA,
int MORSE_zpotrf(MORSE_enum uplo, int N, MORSE_Complex64_t *A, int LDA);
int MORSE_zsytrf(MORSE_enum uplo, int N, MORSE_Complex64_t *A, int LDA);
int MORSE_zpotri(MORSE_enum uplo, int N, MORSE_Complex64_t *A, int LDA);
int MORSE_zpotrimm(MORSE_enum uplo, int N, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB, MORSE_Complex64_t *C, int LDC);
int MORSE_zpotrs(MORSE_enum uplo, int N, int NRHS, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB);
#if defined (PRECISION_c) || defined(PRECISION_z)
int MORSE_zsytrs(MORSE_enum uplo, int N, int NRHS, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB);
#endif
int MORSE_zsymm(MORSE_enum side, MORSE_enum uplo, int M, int N, MORSE_Complex64_t alpha, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB, MORSE_Complex64_t beta, MORSE_Complex64_t *C, int LDC);
int MORSE_zsyrk(MORSE_enum uplo, MORSE_enum trans, int N, int K, MORSE_Complex64_t alpha, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t beta, MORSE_Complex64_t *C, int LDC);
int MORSE_zsyr2k(MORSE_enum uplo, MORSE_enum trans, int N, int K, MORSE_Complex64_t alpha, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB, MORSE_Complex64_t beta, MORSE_Complex64_t *C, int LDC);
int MORSE_zsysv(MORSE_enum uplo, int N, int NRHS, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB);
int MORSE_zsytrs(MORSE_enum uplo, int N, int NRHS, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB);
int MORSE_ztrmm(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, int N, int NRHS, MORSE_Complex64_t alpha, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB);
int MORSE_ztrsm(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, int N, int NRHS, MORSE_Complex64_t alpha, MORSE_Complex64_t *A, int LDA, MORSE_Complex64_t *B, int LDB);
int MORSE_ztrsmpl(int N, int NRHS, MORSE_Complex64_t *A, int LDA, MORSE_desc_t *descL, int *IPIV, MORSE_Complex64_t *B, int LDB);
......@@ -167,13 +167,13 @@ int MORSE_zposv_Tile(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B);
int MORSE_zpotrf_Tile(MORSE_enum uplo, MORSE_desc_t *A);
int MORSE_zsytrf_Tile(MORSE_enum uplo, MORSE_desc_t *A);
int MORSE_zpotri_Tile(MORSE_enum uplo, MORSE_desc_t *A);
int MORSE_zpotrimm_Tile(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_desc_t *C);
int MORSE_zpotrs_Tile(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B);
#if defined (PRECISION_c) || defined(PRECISION_z)
int MORSE_zsytrs_Tile(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B);
#endif
int MORSE_zsymm_Tile(MORSE_enum side, MORSE_enum uplo, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_Complex64_t beta, MORSE_desc_t *C);
int MORSE_zsyrk_Tile(MORSE_enum uplo, MORSE_enum trans, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_Complex64_t beta, MORSE_desc_t *C);
int MORSE_zsyr2k_Tile(MORSE_enum uplo, MORSE_enum trans, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_Complex64_t beta, MORSE_desc_t *C);
int MORSE_zsysv_Tile(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B);
int MORSE_zsytrs_Tile(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B);
int MORSE_ztrmm_Tile(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B);
int MORSE_ztrsm_Tile(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B);
int MORSE_ztrsmpl_Tile(MORSE_desc_t *A, MORSE_desc_t *L, int *IPIV, MORSE_desc_t *B);
......@@ -238,10 +238,10 @@ int MORSE_zposv_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MO
int MORSE_zpotrf_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_sequence_t *sequence, MORSE_request_t *request);
int MORSE_zsytrf_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_sequence_t *sequence, MORSE_request_t *request);
int MORSE_zpotri_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_sequence_t *sequence, MORSE_request_t *request);
int MORSE_zpotrimm_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_desc_t *C, MORSE_sequence_t *sequence, MORSE_request_t *request);
int MORSE_zpotrs_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_sequence_t *sequence, MORSE_request_t *request);
#if defined (PRECISION_c) || defined(PRECISION_z)
int MORSE_zsysv_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_sequence_t *sequence, MORSE_request_t *request);
int MORSE_zsytrs_Tile_Async(MORSE_enum uplo, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_sequence_t *sequence, MORSE_request_t *request);
#endif
int MORSE_zsymm_Tile_Async(MORSE_enum side, MORSE_enum uplo, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_Complex64_t beta, MORSE_desc_t *C, MORSE_sequence_t *sequence, MORSE_request_t *request);
int MORSE_zsyrk_Tile_Async(MORSE_enum uplo, MORSE_enum trans, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_Complex64_t beta, MORSE_desc_t *C, MORSE_sequence_t *sequence, MORSE_request_t *request);
int MORSE_zsyr2k_Tile_Async(MORSE_enum uplo, MORSE_enum trans, MORSE_Complex64_t alpha, MORSE_desc_t *A, MORSE_desc_t *B, MORSE_Complex64_t beta, MORSE_desc_t *C, MORSE_sequence_t *sequence, MORSE_request_t *request);
......
......@@ -42,7 +42,7 @@ extern "C" {
/** ****************************************************************************
* Declarations of QUARK wrappers (called by MORSE) - alphabetical order
**/
void MORSE_TASK_zdasum(MORSE_option_t *options,
void MORSE_TASK_dzasum(MORSE_option_t *options,
MORSE_enum storev, MORSE_enum uplo, int M, int N,
MORSE_desc_t *A, int Am, int An, int lda,
MORSE_desc_t *B, int Bm, int Bn);
......@@ -127,6 +127,9 @@ void MORSE_TASK_zgetrf_incpiv(MORSE_option_t *options,
MORSE_desc_t *L, int Lm, int Ln, int ldl,
int *IPIV,
MORSE_bool check_info, int iinfo);
void MORSE_TASK_zgetrf_nopiv(MORSE_option_t *options,
int m, int n, int ib, int nb,
MORSE_desc_t *A, int Am, int An, int lda, int iinfo);
void MORSE_TASK_zgetrf_reclap(MORSE_option_t *options,
int m, int n, int nb,
MORSE_desc_t *A, int Am, int An, int lda,
......@@ -288,6 +291,10 @@ void MORSE_TASK_zsyssq( MORSE_option_t *options,
MORSE_enum uplo, int n,
MORSE_desc_t *A, int Am, int An, int lda,
MORSE_desc_t *SCALESUMSQ, int SCALESUMSQm, int SCALESUMSQn );
void MORSE_TASK_zsytrf_nopiv(MORSE_option_t *options,
MORSE_enum uplo, int n, int nb,
MORSE_desc_t *A, int Am, int An, int lda,
int iinfo);
void MORSE_TASK_zswpab(MORSE_option_t *options,
int i, int n1, int n2,
MORSE_desc_t *A, int Am, int An, int szeA);
......
......@@ -59,7 +59,6 @@ static void cl_dzasum_cpu_func(void *descr[], void *cl_arg)
MORSE_Complex64_t *A;
int lda;
double *work;
int m, n;
A = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[0]);
work = (double *)STARPU_MATRIX_GET_PTR(descr[1]);
......
......@@ -58,7 +58,6 @@ static void cl_zaxpy_cpu_func(void *descr[], void *cl_arg)
int incA;
MORSE_Complex64_t *B;
int incB;
int m, n;
A = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[0]);
B = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[1]);
......
......@@ -52,10 +52,12 @@ void MORSE_TASK_zgemm(MORSE_option_t *options,
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
......
......@@ -121,14 +121,12 @@ static void cl_zgessm_cpu_func(void *descr[], void *cl_arg)
int k;
int ib;
int *IPIV;
MORSE_Complex64_t *L;
int ldl;
MORSE_Complex64_t *D;
int ldd;
MORSE_Complex64_t *A;
int lda;
L = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[0]);
D = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[1]);
A = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[2]);
starpu_codelet_unpack_args(cl_arg, &m, &n, &k, &ib, &IPIV, &ldl, &ldd, &lda);
......
......@@ -130,7 +130,7 @@ static void cl_zgetrf_incpiv_cpu_func(void *descr[], void *cl_arg)
int m;
int n;
int ib;
MORSE_Complex64_t *A, *L;
MORSE_Complex64_t *A;
int lda, ldl;
int *IPIV;
MORSE_bool check_info;
......@@ -139,30 +139,32 @@ static void cl_zgetrf_incpiv_cpu_func(void *descr[], void *cl_arg)
int info = 0;
A = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[0]);
L = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[1]);
starpu_codelet_unpack_args(cl_arg, &m, &n, &ib, &lda, &ldl, &IPIV, &check_info, &iinfo, &h_work);
CORE_zgetrf_incpiv(m, n, ib, A, lda, IPIV, &info);
#if defined(CHAMELEON_USE_MAGMA)
/*
* L stores:
* L1 L2 L3 ...
* L1^-1 L2^-1 L3^-1 ...
*/
/* Compute L-1 in lower rectangle of L */
if ( ldl >= 2*ib )
{
int i, sb;
L += ib;
for (i=0; i<n; i+=ib) {
sb = min( ib, n-i );
CORE_zlacpy(MorseUpperLower, sb, sb, A+(i*lda+i), lda, L+(i*ldl), ldl );
CORE_ztrtri( MorseLower, MorseUnit, sb, L+(i*ldl), ldl, &info );
if (info != 0 ) {
fprintf(stderr, "ERROR, trtri returned with info = %d\n", info);
MORSE_Complex64_t *L = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[1]);
/*
* L stores:
* L1 L2 L3 ...
* L1^-1 L2^-1 L3^-1 ...
*/
/* Compute L-1 in lower rectangle of L */
if ( ldl >= 2*ib )
{
int i, sb;
L += ib;
for (i=0; i<n; i+=ib) {
sb = min( ib, n-i );
CORE_zlacpy(MorseUpperLower, sb, sb, A+(i*lda+i), lda, L+(i*ldl), ldl );
CORE_ztrtri( MorseLower, MorseUnit, sb, L+(i*ldl), ldl, &info );
if (info != 0 ) {
fprintf(stderr, "ERROR, trtri returned with info = %d\n", info);
}
}
}
}
......
......@@ -65,12 +65,11 @@ static void cl_zsytrf_nopiv_cpu_func(void *descr[], void *cl_arg)
MORSE_Complex64_t *A;
int lda;
int iinfo;
int info = 0;
A = (MORSE_Complex64_t *)STARPU_MATRIX_GET_PTR(descr[0]);
starpu_codelet_unpack_args(cl_arg, &uplo, &n, &lda, &iinfo);
info = CORE_zsytf2_nopiv(uplo, n, A, lda);
CORE_zsytf2_nopiv(uplo, n, A, lda);
}
/*
......
......@@ -50,6 +50,7 @@ void MORSE_TASK_ztrsm(MORSE_option_t *options,
int sizeB = ldb*n;
int execution_rank = B->get_rankof( B, Bm, Bn );
int rank_changed=0;
(void)execution_rank;