LASs - Linear Algebra Routines on OmpSs 1.0.0 LASs

- Main Page
- Files

- File List
- File Members

ddss_dtpgetrf.c
Go to the documentation of this file.
1 #include "../include/lass.h"
2
3 /**
4 *
5 * @file ddss_dtpgetrf.c
6 *
7 * @brief LASs-DDSs ddss_dtpgetrf routine.
8 *
9 * LASs-DDSs is a software package provided by:
10 * Barcelona Supercomputing Center - Centro Nacional de Supercomputacion
11 *
12 * @author Pedro Valero-Lara pedro.valero@bsc.es
13 * @author Boro Sofranac boro.sofranac@bsc.es
14 * @date 2018-04-08
15 * @reviewer
16 * @modified 2018-05-08
17 *
18 **/
19
20 /**
21 *
22 * @ingroup DDSS
23 *
24 * Performs the LU factorization with tiled pivoting ( row interchanges )
25 * of a general M-by-N matrix A:
26 *
27 * A = P * L * U
28 *
29 * where P is a permutation matrix, L is a lower triangular
30 * ( lower trapezoidal if M > N ) matrix with unit diagonal elements and
31 * U is an upper triangular ( upper trapezoidal if M < N ) matrix.
32 *
33 **/
34
35 /**
36 *
37 * @param[in]
38 * M int.
39 * M specifies the number of rows of the matrix A. M >= 0.
40 *
41 * @param[in]
42 * N int.
43 * N specifies the number of columns of the matrix A. N >= 0.
44 *
45 * @param[in,out]
46 * A double *.
47 * A is a pointer to a regular matrix of dimension M-by-N.
48 * On exit, if return value is Success, the matrix A is overwriten by
49 * the factors L and U. The unit diagonal elements of L are not stored.
50 *
51 * @param[in]
52 * LDA int.
53 * LDA specifies the number of columns of A ( row-major order ).
54 * LDA must be at least max( 1, N ).
55 *
56 * @param[out]
57 * IPIV int *.
58 * ipiv is a pointer to an array of dimesion at least
59 * max( 1, min ( M, N ) ). ipiv( i ) = j, 1 <= i <= min( M, N ) implies
60 * that rows i and j have been interchanged.
61 *
62 **/
63
64 /**
65 *
66 * @retval Success successful exit
67 * @retval NoSuccess unsuccessful exit
68 *
69 **/
70
71 /**
72 *
73 * @sa kdtpgetrf
74 *
75 **/
76
77 int ddss_dtpgetrf( int M, int N, double *A, int LDA, int *IPIV )
78 {
79
80 // Argument checking
81 if ( M < 0 )
82 {
83 fprintf( stderr, "Illegal value of M, in ddss_dtpgetrf code\n" );
84 return NoSuccess;
85 }
86
87 if ( N < 0 )
88 {
89 fprintf( stderr, "Illegal value of N, in ddss_dtpgetrf code\n" );
90 return NoSuccess;
91 }
92
93 if ( LDA < MAX( 1, N ) )
94 {
95 fprintf( stderr, "Illegal value of LDA, in ddss_dtpgetrf code\n" );
96 return NoSuccess;
97 }
98
99 // Qick return
100 if ( MIN( M, N ) == 0 )
101 {
102 return Success;
103 }
104
105 return kdtpgetrf( M, N, A, LDA, IPIV );
106
107 }
ddss_dtpgetrf
int ddss_dtpgetrf(int M, int N, double *A, int LDA, int *IPIV)
Definition: ddss_dtpgetrf.c:77
kdtpgetrf
enum LASS_RETURN kdtpgetrf(int M, int N, double *A, int LDA, int *IPIV)
Definition: kdtpgetrf.c:80