![]() |
MAGMA
1.5.0
Matrix Algebra for GPU and Multicore Architectures
|
Functions | |
void | magma_dprint (magma_int_t m, magma_int_t n, const double *A, magma_int_t lda) |
magma_dprint prints a matrix that is located on the CPU host. More... | |
void | magma_dprint_gpu (magma_int_t m, magma_int_t n, const double *dA, magma_int_t ldda) |
magma_dprint_gpu prints a matrix that is located on the GPU device. More... | |
magma_int_t | magma_dnan_inf (magma_uplo_t uplo, magma_int_t m, magma_int_t n, const double *A, magma_int_t lda, magma_int_t *cnt_nan, magma_int_t *cnt_inf) |
magma_dnan_inf checks a matrix that is located on the CPU host for NAN (not-a-number) and INF (infinity) values. More... | |
magma_int_t | magma_dnan_inf_gpu (magma_uplo_t uplo, magma_int_t m, magma_int_t n, const double *dA, magma_int_t ldda, magma_int_t *cnt_nan, magma_int_t *cnt_inf) |
magma_dnan_inf checks a matrix that is located on the CPU host for NAN (not-a-number) and INF (infinity) values. More... | |
void | magmablas_dgeadd (magma_int_t m, magma_int_t n, double alpha, const double *dA, magma_int_t ldda, double *dB, magma_int_t lddb) |
ZGEADD adds two matrices, dB = alpha*dA + dB. More... | |
void | magmablas_dgeadd_batched (magma_int_t m, magma_int_t n, double alpha, const double *const *dAarray, magma_int_t ldda, double **dBarray, magma_int_t lddb, magma_int_t batchCount) |
ZGEADD adds two sets of matrices, dAarray[i] = alpha*dAarray[i] + dBarray[i], for i = 0, ..., batchCount-1. More... | |
void | magmablas_dlacpy (magma_uplo_t uplo, magma_int_t m, magma_int_t n, const double *dA, magma_int_t ldda, double *dB, magma_int_t lddb) |
NoteMore... | |
void | magmablas_dlacpy_batched (magma_uplo_t uplo, magma_int_t m, magma_int_t n, const double *const *dAarray, magma_int_t ldda, double **dBarray, magma_int_t lddb, magma_int_t batchCount) |
NoteMore... | |
void | magmablas_dlag2s (magma_int_t m, magma_int_t n, const double *A, magma_int_t lda, float *SA, magma_int_t ldsa, magma_int_t *info) |
DLAG2S converts a double-real matrix, A, to a single-real matrix, SA. More... | |
double | magmablas_dlange (magma_norm_t norm, magma_int_t m, magma_int_t n, const double *A, magma_int_t lda, double *dwork) |
DLANGE returns the value of the one norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a real matrix A. More... | |
double | magmablas_dlansy (magma_norm_t norm, magma_uplo_t uplo, magma_int_t n, const double *A, magma_int_t lda, double *dwork) |
DLANSY returns the value of the one norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a real symmetric matrix A. More... | |
void | magmablas_dlaset_stream (magma_uplo_t uplo, magma_int_t m, magma_int_t n, double offdiag, double diag, double *dA, magma_int_t ldda, magma_queue_t stream) |
DLASET_STREAM initializes a 2-D array A to DIAG on the diagonal and OFFDIAG on the off-diagonals. More... | |
void | magmablas_dlaset (magma_uplo_t uplo, magma_int_t m, magma_int_t n, double offdiag, double diag, double *dA, magma_int_t ldda) |
void | magmablas_dlaset_band_stream (magma_uplo_t uplo, magma_int_t m, magma_int_t n, magma_int_t k, double offdiag, double diag, double *dA, magma_int_t ldda, magma_queue_t stream) |
DLASET_BAND_STREAM initializes the main diagonal of dA to DIAG, and the K-1 sub- or super-diagonals to OFFDIAG. More... | |
void | magmablas_dlaset_band (magma_uplo_t uplo, magma_int_t m, magma_int_t n, magma_int_t k, double offdiag, double diag, double *dA, magma_int_t ldda) |
void | magmablas_dslaswp (magma_int_t n, double *a, magma_int_t lda, float *sa, magma_int_t m, const magma_int_t *ipiv, magma_int_t incx) |
Row i of A is cast to single precision in row ipiv[i] of SA, for 0 <= i < M. More... | |
void | magmablas_dswapdblk (magma_int_t n, magma_int_t nb, double *dA1, magma_int_t ldda1, magma_int_t inca1, double *dA2, magma_int_t ldda2, magma_int_t inca2) |
This is an auxiliary MAGMA routine. More... | |
void | magmablas_dsymmetrize (magma_uplo_t uplo, magma_int_t m, double *dA, magma_int_t ldda) |
DSYMMETRIZE copies lower triangle to upper triangle, or vice-versa, to make dA a general representation of a symmetric matrix. More... | |
void | magmablas_dsymmetrize_tiles (magma_uplo_t uplo, magma_int_t m, double *dA, magma_int_t ldda, magma_int_t ntile, magma_int_t mstride, magma_int_t nstride) |
DSYMMETRIZE_TILES copies lower triangle to upper triangle, or vice-versa, to make some blocks of dA into general representations of a symmetric block. More... | |
void | magmablas_dtranspose_stream (magma_int_t m, magma_int_t n, const double *dA, magma_int_t ldda, double *dAT, magma_int_t lddat, magma_queue_t stream) |
dtranspose_stream copies and transposes a matrix dA to matrix dAT. More... | |
void | magmablas_dtranspose (magma_int_t m, magma_int_t n, const double *dA, magma_int_t ldda, double *dAT, magma_int_t lddat) |
void | magmablas_dtranspose_inplace_stream (magma_int_t n, double *dA, magma_int_t ldda, magma_queue_t stream) |
dtranspose_inplace_stream transposes a square N-by-N matrix in-place. More... | |
void | magmablas_dtranspose_inplace (magma_int_t n, double *dA, magma_int_t ldda) |
magma_int_t magma_dnan_inf | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
magma_int_t | n, | ||
const double * | A, | ||
magma_int_t | lda, | ||
magma_int_t * | cnt_nan, | ||
magma_int_t * | cnt_inf | ||
) |
magma_dnan_inf checks a matrix that is located on the CPU host for NAN (not-a-number) and INF (infinity) values.
NAN is created by 0/0 and similar. INF is created by x/0 and similar, where x != 0.
[in] | uplo | magma_uplo_t Specifies what part of the matrix A to check.
|
[in] | m | INTEGER The number of rows of the matrix A. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix A. N >= 0. |
[in] | A | DOUBLE_PRECISION array, dimension (LDA,N), on the CPU host. The M-by-N matrix to be printed. |
[in] | lda | INTEGER The leading dimension of the array A. LDA >= max(1,M). |
[out] | cnt_nan | INTEGER* If non-NULL, on exit contains the number of NAN values in A. |
[out] | cnt_inf | INTEGER* If non-NULL, on exit contains the number of INF values in A. |
magma_int_t magma_dnan_inf_gpu | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
magma_int_t | n, | ||
const double * | dA, | ||
magma_int_t | ldda, | ||
magma_int_t * | cnt_nan, | ||
magma_int_t * | cnt_inf | ||
) |
magma_dnan_inf checks a matrix that is located on the CPU host for NAN (not-a-number) and INF (infinity) values.
NAN is created by 0/0 and similar. INF is created by x/0 and similar, where x != 0.
[in] | uplo | magma_uplo_t Specifies what part of the matrix A to check.
|
[in] | m | INTEGER The number of rows of the matrix A. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix A. N >= 0. |
[in,out] | dA | DOUBLE_PRECISION array, dimension (LDDA,N), on the GPU device. The M-by-N matrix to be printed. |
[in] | ldda | INTEGER The leading dimension of the array A. LDDA >= max(1,M). |
[out] | cnt_nan | INTEGER* If non-NULL, on exit contains the number of NAN values in A. |
[out] | cnt_inf | INTEGER* If non-NULL, on exit contains the number of INF values in A. |
void magma_dprint | ( | magma_int_t | m, |
magma_int_t | n, | ||
const double * | A, | ||
magma_int_t | lda | ||
) |
magma_dprint prints a matrix that is located on the CPU host.
The output is intended to be Matlab compatible, to be useful in debugging.
[in] | m | INTEGER The number of rows of the matrix A. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix A. N >= 0. |
[in] | A | DOUBLE_PRECISION array, dimension (LDA,N), on the CPU host. The M-by-N matrix to be printed. |
[in] | lda | INTEGER The leading dimension of the array A. LDA >= max(1,M). |
void magma_dprint_gpu | ( | magma_int_t | m, |
magma_int_t | n, | ||
const double * | dA, | ||
magma_int_t | ldda | ||
) |
magma_dprint_gpu prints a matrix that is located on the GPU device.
Internally, it allocates CPU memory and copies the matrix to the CPU. The output is intended to be Matlab compatible, to be useful in debugging.
[in] | m | INTEGER The number of rows of the matrix A. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix A. N >= 0. |
[in] | dA | DOUBLE_PRECISION array, dimension (LDDA,N), on the GPU device. The M-by-N matrix to be printed. |
[in] | ldda | INTEGER The leading dimension of the array A. LDDA >= max(1,M). |
void magmablas_dgeadd | ( | magma_int_t | m, |
magma_int_t | n, | ||
double | alpha, | ||
const double * | dA, | ||
magma_int_t | ldda, | ||
double * | dB, | ||
magma_int_t | lddb | ||
) |
ZGEADD adds two matrices, dB = alpha*dA + dB.
[in] | m | INTEGER The number of rows of the matrix dA. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix dA. N >= 0. |
[in] | alpha | DOUBLE_PRECISION The scalar alpha. |
[in] | dA | DOUBLE_PRECISION array, dimension (LDDA,N) The m by n matrix dA. |
[in] | ldda | INTEGER The leading dimension of the array dA. LDDA >= max(1,M). |
[in,out] | dB | DOUBLE_PRECISION array, dimension (LDDB,N) The m by n matrix dB. |
[in] | lddb | INTEGER The leading dimension of the array dB. LDDB >= max(1,M). |
void magmablas_dgeadd_batched | ( | magma_int_t | m, |
magma_int_t | n, | ||
double | alpha, | ||
const double *const * | dAarray, | ||
magma_int_t | ldda, | ||
double ** | dBarray, | ||
magma_int_t | lddb, | ||
magma_int_t | batchCount | ||
) |
ZGEADD adds two sets of matrices, dAarray[i] = alpha*dAarray[i] + dBarray[i], for i = 0, ..., batchCount-1.
[in] | m | INTEGER The number of rows of each matrix dAarray[i]. M >= 0. |
[in] | n | INTEGER The number of columns of each matrix dAarray[i]. N >= 0. |
[in] | alpha | DOUBLE_PRECISION The scalar alpha. |
[in] | dAarray | array on GPU, dimension(batchCount), of pointers to arrays, with each array a DOUBLE_PRECISION array, dimension (LDDA,N) The m by n matrices dAarray[i]. |
[in] | ldda | INTEGER The leading dimension of each array dAarray[i]. LDDA >= max(1,M). |
[in,out] | dBarray | array on GPU, dimension(batchCount), of pointers to arrays, with each array a DOUBLE_PRECISION array, dimension (LDDB,N) The m by n matrices dBarray[i]. |
[in] | lddb | INTEGER The leading dimension of each array dBarray[i]. LDDB >= max(1,M). |
[in] | batchCount | INTEGER The number of matrices to add; length of dAarray and dBarray. batchCount >= 0. |
void magmablas_dlacpy | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
magma_int_t | n, | ||
const double * | dA, | ||
magma_int_t | ldda, | ||
double * | dB, | ||
magma_int_t | lddb | ||
) |
DLACPY copies all or part of a two-dimensional matrix dA to another matrix dB.
[in] | uplo | magma_uplo_t Specifies the part of the matrix dA to be copied to dB.
|
[in] | m | INTEGER The number of rows of the matrix dA. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix dA. N >= 0. |
[in] | dA | DOUBLE_PRECISION array, dimension (LDDA,N) The m by n matrix dA. If UPLO = MagmaUpper, only the upper triangle or trapezoid is accessed; if UPLO = MagmaLower, only the lower triangle or trapezoid is accessed. |
[in] | ldda | INTEGER The leading dimension of the array dA. LDDA >= max(1,M). |
[out] | dB | DOUBLE_PRECISION array, dimension (LDDB,N) The m by n matrix dB. On exit, dB = dA in the locations specified by UPLO. |
[in] | lddb | INTEGER The leading dimension of the array dB. LDDB >= max(1,M). |
void magmablas_dlacpy_batched | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
magma_int_t | n, | ||
const double *const * | dAarray, | ||
magma_int_t | ldda, | ||
double ** | dBarray, | ||
magma_int_t | lddb, | ||
magma_int_t | batchCount | ||
) |
DLACPY copies all or part of a set of two-dimensional matrices dAarray[i] to another set of matrices dBarray[i], for i = 0, ..., batchCount-1.
[in] | uplo | magma_uplo_t Specifies the part of each matrix dAarray[i] to be copied to dBarray[i].
|
[in] | m | INTEGER The number of rows of each matrix dAarray[i]. M >= 0. |
[in] | n | INTEGER The number of columns of each matrix dAarray[i]. N >= 0. |
[in] | dAarray | array on GPU, dimension(batchCount), of pointers to arrays, with each array a DOUBLE_PRECISION array, dimension (LDDA,N) The m by n matrices dAarray[i]. If UPLO = MagmaUpper, only the upper triangle or trapezoid is accessed; if UPLO = MagmaLower, only the lower triangle or trapezoid is accessed. |
[in] | ldda | INTEGER The leading dimension of each array dAarray[i]. LDDA >= max(1,M). |
[out] | dBarray | array on GPU, dimension(batchCount), of pointers to arrays, with each array a DOUBLE_PRECISION array, dimension (LDDB,N) The m by n matrices dBarray[i]. On exit, matrix dBarray[i] = matrix dAarray[i] in the locations specified by UPLO. |
[in] | lddb | INTEGER The leading dimension of each array dBarray[i]. LDDB >= max(1,M). |
[in] | batchCount | INTEGER The number of matrices to add; length of dAarray and dBarray. batchCount >= 0. |
void magmablas_dlag2s | ( | magma_int_t | m, |
magma_int_t | n, | ||
const double * | A, | ||
magma_int_t | lda, | ||
float * | SA, | ||
magma_int_t | ldsa, | ||
magma_int_t * | info | ||
) |
DLAG2S converts a double-real matrix, A, to a single-real matrix, SA.
RMAX is the overflow for the single-real arithmetic. DLAG2S checks that all the entries of A are between -RMAX and RMAX. If not, the conversion is aborted and a flag is raised.
[in] | m | INTEGER The number of lines of the matrix A. m >= 0. |
[in] | n | INTEGER The number of columns of the matrix A. n >= 0. |
[in] | A | DOUBLE PRECISION array, dimension (LDA,n) On entry, the m-by-n coefficient matrix A. |
[in] | lda | INTEGER The leading dimension of the array A. LDA >= max(1,m). |
[out] | SA | SINGLE PRECISION array, dimension (LDSA,n) On exit, if INFO=0, the m-by-n coefficient matrix SA; if INFO>0, the content of SA is unspecified. |
[in] | ldsa | INTEGER The leading dimension of the array SA. LDSA >= max(1,m). |
[out] | info | INTEGER
|
double magmablas_dlange | ( | magma_norm_t | norm, |
magma_int_t | m, | ||
magma_int_t | n, | ||
const double * | A, | ||
magma_int_t | lda, | ||
double * | dwork | ||
) |
DLANGE returns the value of the one norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a real matrix A.
DLANGE returns the value
DLANGE = ( max(abs(A(i,j))), NORM = 'M' or 'm' ** not yet supported ( ( norm1(A), NORM = '1', 'O' or 'o' ** not yet supported ( ( normI(A), NORM = 'I' or 'i' ( ( normF(A), NORM = 'F', 'f', 'E' or 'e' ** not yet supported
where norm1 denotes the one norm of a matrix (maximum column sum), normI denotes the infinity norm of a matrix (maximum row sum) and normF denotes the Frobenius norm of a matrix (square root of sum of squares). Note that max(abs(A(i,j))) is not a consistent matrix norm.
[in] | norm | CHARACTER*1 Specifies the value to be returned in DLANGE as described above. |
[in] | m | INTEGER The number of rows of the matrix A. M >= 0. When M = 0, DLANGE is set to zero. |
[in] | n | INTEGER The number of columns of the matrix A. N >= 0. When N = 0, DLANGE is set to zero. |
[in] | A | DOUBLE PRECISION array on the GPU, dimension (LDA,N) The m by n matrix A. |
[in] | lda | INTEGER The leading dimension of the array A. LDA >= max(M,1). |
dwork | (workspace) DOUBLE PRECISION array on the GPU, dimension (MAX(1,LWORK)), where LWORK >= M when NORM = 'I'; otherwise, WORK is not referenced. |
double magmablas_dlansy | ( | magma_norm_t | norm, |
magma_uplo_t | uplo, | ||
magma_int_t | n, | ||
const double * | A, | ||
magma_int_t | lda, | ||
double * | dwork | ||
) |
DLANSY returns the value of the one norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a real symmetric matrix A.
DLANSY = ( max(abs(A(i,j))), NORM = 'M' or 'm' ( ( norm1(A), NORM = '1', 'O' or 'o' ** supported only for (PRECISION_s || PRECISION_d || PRECISION_c || CUDA_ARCH >= 200) ( ( normI(A), NORM = 'I' or 'i' ** supported only for (PRECISION_s || PRECISION_d || PRECISION_c || CUDA_ARCH >= 200) ( ( normF(A), NORM = 'F', 'f', 'E' or 'e' ** not yet supported
where norm1 denotes the one norm of a matrix (maximum column sum), normI denotes the infinity norm of a matrix (maximum row sum) and normF denotes the Frobenius norm of a matrix (square root of sum of squares). Note that max(abs(A(i,j))) is not a consistent matrix norm.
Returns DLANSY < 0: if DLANSY = -i, the i-th argument had an illegal value.
[in] | norm | CHARACTER*1 Specifies the value to be returned in DLANSY as described above. |
[in] | uplo | magma_uplo_t Specifies whether the upper or lower triangular part of the symmetric matrix A is to be referenced.
|
[in] | n | INTEGER The order of the matrix A. N >= 0. When N = 0, DLANSY is set to zero. |
[in] | A | DOUBLE PRECISION array on the GPU, dimension (LDA,N) The symmetric matrix A. If UPLO = MagmaUpper, the leading n by n upper triangular part of A contains the upper triangular part of the matrix A, and the strictly lower triangular part of A is not referenced. If UPLO = MagmaLower, the leading n by n lower triangular part of A contains the lower triangular part of the matrix A, and the strictly upper triangular part of A is not referenced. Note that the imaginary parts of the diagonal elements need not be set and are assumed to be zero. |
[in] | lda | INTEGER The leading dimension of the array A. LDA >= max(N,1). |
dwork | (workspace) DOUBLE PRECISION array on the GPU, dimension (MAX(1,LWORK)), where LWORK >= N. NOTE: this is different than LAPACK, where WORK is required only for norm1 and normI. Here max-norm also requires work. |
void magmablas_dlaset | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
magma_int_t | n, | ||
double | offdiag, | ||
double | diag, | ||
double * | dA, | ||
magma_int_t | ldda | ||
) |
void magmablas_dlaset_band | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
magma_int_t | n, | ||
magma_int_t | k, | ||
double | offdiag, | ||
double | diag, | ||
double * | dA, | ||
magma_int_t | ldda | ||
) |
void magmablas_dlaset_band_stream | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
magma_int_t | n, | ||
magma_int_t | k, | ||
double | offdiag, | ||
double | diag, | ||
double * | dA, | ||
magma_int_t | ldda, | ||
magma_queue_t | stream | ||
) |
DLASET_BAND_STREAM initializes the main diagonal of dA to DIAG, and the K-1 sub- or super-diagonals to OFFDIAG.
This is the same as DLASET_BAND, but adds stream argument.
[in] | uplo | magma_uplo_t Specifies the part of the matrix dA to be set.
|
[in] | m | INTEGER The number of rows of the matrix dA. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix dA. N >= 0. |
[in] | k | INTEGER The number of diagonals to set, including the main diagonal. K >= 0. Currently, K <= 1024 due to CUDA restrictions (max. number of threads per block). |
[in] | offdiag | DOUBLE_PRECISION Off-diagonal elements in the band are set to OFFDIAG. |
[in] | diag | DOUBLE_PRECISION All the main diagonal elements are set to DIAG. |
[in] | dA | DOUBLE_PRECISION array, dimension (LDDA,N) The M-by-N matrix dA. If UPLO = MagmaUpper, only the upper triangle or trapezoid is accessed; if UPLO = MagmaLower, only the lower triangle or trapezoid is accessed. On exit, A(i,j) = ALPHA, 1 <= i <= m, 1 <= j <= n where i != j, abs(i-j) < k; A(i,i) = BETA , 1 <= i <= min(m,n) |
[in] | ldda | INTEGER The leading dimension of the array dA. LDDA >= max(1,M). |
[in] | stream | magma_queue_t Stream to execute DLASET in. |
void magmablas_dlaset_stream | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
magma_int_t | n, | ||
double | offdiag, | ||
double | diag, | ||
double * | dA, | ||
magma_int_t | ldda, | ||
magma_queue_t | stream | ||
) |
DLASET_STREAM initializes a 2-D array A to DIAG on the diagonal and OFFDIAG on the off-diagonals.
This is the same as DLASET, but adds stream argument.
[in] | uplo | magma_uplo_t Specifies the part of the matrix dA to be set.
|
[in] | m | INTEGER The number of rows of the matrix dA. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix dA. N >= 0. |
[in] | offdiag | DOUBLE_PRECISION The scalar OFFDIAG. (In LAPACK this is called ALPHA.) |
[in] | diag | DOUBLE_PRECISION The scalar DIAG. (In LAPACK this is called BETA.) |
[in] | dA | DOUBLE_PRECISION array, dimension (LDDA,N) The M-by-N matrix dA. If UPLO = MagmaUpper, only the upper triangle or trapezoid is accessed; if UPLO = MagmaLower, only the lower triangle or trapezoid is accessed. On exit, A(i,j) = OFFDIAG, 1 <= i <= m, 1 <= j <= n, i != j; A(i,i) = DIAG, 1 <= i <= min(m,n) |
[in] | ldda | INTEGER The leading dimension of the array dA. LDDA >= max(1,M). |
[in] | stream | magma_queue_t Stream to execute in. |
void magmablas_dslaswp | ( | magma_int_t | n, |
double * | a, | ||
magma_int_t | lda, | ||
float * | sa, | ||
magma_int_t | m, | ||
const magma_int_t * | ipiv, | ||
magma_int_t | incx | ||
) |
Row i of A is cast to single precision in row ipiv[i] of SA, for 0 <= i < M.
N - (input) INTEGER. On entry, N specifies the number of columns of the matrix A.
A - (input) DOUBLE PRECISION array on the GPU, dimension (LDA,N) On entry, the M-by-N matrix to which the row interchanges will be applied.
LDA - (input) INTEGER. LDA specifies the leading dimension of A.
SA - (output) REAL array on the GPU, dimension (LDA,N) On exit, the single precision, permuted matrix.
M - (input) The number of rows to be interchanged.
IPIV - (input) INTEGER array on the GPU, dimension (M) The vector of pivot indices. Row i of A is cast to single precision in row ipiv[i] of SA, for 0 <= i < m.
INCX - (input) INTEGER If IPIV is negative, the pivots are applied in reverse order, otherwise in straight-forward order.
void magmablas_dswapdblk | ( | magma_int_t | n, |
magma_int_t | nb, | ||
double * | dA1, | ||
magma_int_t | ldda1, | ||
magma_int_t | inca1, | ||
double * | dA2, | ||
magma_int_t | ldda2, | ||
magma_int_t | inca2 | ||
) |
This is an auxiliary MAGMA routine.
It swaps diagonal blocks of size nb x nb between matrices dA1 and dA2 on the GPU.
The number of blocks swapped is (n-1)/nb. For i = 1 .. (n-1)/nb matrices dA1 + i * nb * (ldda1 + inca1) and dA2 + i * nb * (ldda2 + inca2) are swapped.
void magmablas_dsymmetrize | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
double * | dA, | ||
magma_int_t | ldda | ||
) |
DSYMMETRIZE copies lower triangle to upper triangle, or vice-versa, to make dA a general representation of a symmetric matrix.
[in] | uplo | magma_uplo_t Specifies the part of the matrix dA that is valid on input.
|
[in] | m | INTEGER The number of rows of the matrix dA. M >= 0. |
[in,out] | dA | DOUBLE_PRECISION array, dimension (LDDA,N) The m by m matrix dA. |
[in] | ldda | INTEGER The leading dimension of the array dA. LDDA >= max(1,M). |
void magmablas_dsymmetrize_tiles | ( | magma_uplo_t | uplo, |
magma_int_t | m, | ||
double * | dA, | ||
magma_int_t | ldda, | ||
magma_int_t | ntile, | ||
magma_int_t | mstride, | ||
magma_int_t | nstride | ||
) |
DSYMMETRIZE_TILES copies lower triangle to upper triangle, or vice-versa, to make some blocks of dA into general representations of a symmetric block.
This processes NTILE blocks, typically the diagonal blocks. Each block is offset by mstride rows and nstride columns from the previous block.
[in] | uplo | magma_uplo_t Specifies the part of the matrix dA that is valid on input.
|
[in] | m | INTEGER The number of rows & columns of each square block of dA. M >= 0. |
[in,out] | dA | DOUBLE_PRECISION array, dimension (LDDA,N) The matrix dA. N = m + nstride*(ntile-1). |
[in] | ldda | INTEGER The leading dimension of the array dA. LDDA >= max(1, m + mstride*(ntile-1)). |
[in] | ntile | INTEGER Number of blocks to symmetrize. |
[in] | mstride | INTEGER Row offset from start of one block to start of next block. |
[in] | nstride | INTEGER Column offset from start of one block to start of next block. |
void magmablas_dtranspose | ( | magma_int_t | m, |
magma_int_t | n, | ||
const double * | dA, | ||
magma_int_t | ldda, | ||
double * | dAT, | ||
magma_int_t | lddat | ||
) |
void magmablas_dtranspose_inplace | ( | magma_int_t | n, |
double * | dA, | ||
magma_int_t | ldda | ||
) |
void magmablas_dtranspose_inplace_stream | ( | magma_int_t | n, |
double * | dA, | ||
magma_int_t | ldda, | ||
magma_queue_t | stream | ||
) |
dtranspose_inplace_stream transposes a square N-by-N matrix in-place.
Same as dtranspose_inplace, but adds stream argument.
[in] | n | INTEGER The number of rows & columns of the matrix dA. N >= 0. |
[in] | dA | DOUBLE_PRECISION array, dimension (LDDA,N) The N-by-N matrix dA. On exit, dA(j,i) = dA_original(i,j), for 0 <= i,j < N. |
[in] | ldda | INTEGER The leading dimension of the array dA. LDDA >= N. |
[in] | stream | magma_queue_t Stream to execute in. |
void magmablas_dtranspose_stream | ( | magma_int_t | m, |
magma_int_t | n, | ||
const double * | dA, | ||
magma_int_t | ldda, | ||
double * | dAT, | ||
magma_int_t | lddat, | ||
magma_queue_t | stream | ||
) |
dtranspose_stream copies and transposes a matrix dA to matrix dAT.
Same as dtranspose, but adds stream argument.
[in] | m | INTEGER The number of rows of the matrix dA. M >= 0. |
[in] | n | INTEGER The number of columns of the matrix dA. N >= 0. |
[in] | dA | DOUBLE_PRECISION array, dimension (LDDA,N) The M-by-N matrix dA. |
[in] | ldda | INTEGER The leading dimension of the array dA. LDDA >= M. |
[in] | dAT | DOUBLE_PRECISION array, dimension (LDDA,N) The N-by-M matrix dAT. |
[in] | lddat | INTEGER The leading dimension of the array dAT. LDDAT >= N. |
[in] | stream | magma_queue_t Stream to execute in. |