PLASMA  2.4.5
PLASMA - Parallel Linear Algebra for Scalable Multi-core Architectures
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
core_sgetrf.c
Go to the documentation of this file.
1 
15 #include <lapacke.h>
16 #include "common.h"
17 
18 #if defined(PLASMA_HAVE_WEAK)
19 #pragma weak CORE_sgetrf = PCORE_sgetrf
20 #define CORE_sgetrf PCORE_sgetrf
21 #endif
22 int CORE_sgetrf(int m, int n,
23  float *A, int lda,
24  int *IPIV, int *info)
25 {
26  *info = LAPACKE_sgetrf_work(LAPACK_COL_MAJOR, m, n, A, lda, IPIV );
27  return PLASMA_SUCCESS;
28 }
29 
30 /***************************************************************************/
33 void QUARK_CORE_sgetrf(Quark *quark, Quark_Task_Flags *task_flags,
34  int m, int n, int nb,
35  float *A, int lda,
36  int *IPIV,
37  PLASMA_sequence *sequence, PLASMA_request *request,
38  PLASMA_bool check_info, int iinfo)
39 {
41  QUARK_Insert_Task(quark, CORE_sgetrf_quark, task_flags,
42  sizeof(int), &m, VALUE,
43  sizeof(int), &n, VALUE,
44  sizeof(float)*nb*nb, A, INOUT | LOCALITY,
45  sizeof(int), &lda, VALUE,
46  sizeof(int)*nb, IPIV, OUTPUT,
47  sizeof(PLASMA_sequence*), &sequence, VALUE,
48  sizeof(PLASMA_request*), &request, VALUE,
49  sizeof(PLASMA_bool), &check_info, VALUE,
50  sizeof(int), &iinfo, VALUE,
51  0);
52 }
53 
54 /***************************************************************************/
57 #if defined(PLASMA_HAVE_WEAK)
58 #pragma weak CORE_sgetrf_quark = PCORE_sgetrf_quark
59 #define CORE_sgetrf_quark PCORE_sgetrf_quark
60 #endif
62 {
63  int m;
64  int n;
65  float *A;
66  int lda;
67  int *IPIV;
68  PLASMA_sequence *sequence;
69  PLASMA_request *request;
70  PLASMA_bool check_info;
71  int iinfo;
72  int info;
73 
74  quark_unpack_args_9(quark, m, n, A, lda, IPIV, sequence, request, check_info, iinfo);
75  info = LAPACKE_sgetrf_work(LAPACK_COL_MAJOR, m, n, A, lda, IPIV );
76  if (info != PLASMA_SUCCESS && check_info)
77  plasma_sequence_flush(quark, sequence, request, iinfo+info);
78 }