14{
15 int info = 0;
16#ifdef FLA_ENABLE_EXTERNAL_LAPACK_INTERFACES
18
19 int m_B, n_B;
20 int cs_A;
21 int cs_B;
22 int k_t;
23 int lwork;
25 char blas_side;
26 char blas_vect = 'Q';
27 char blas_trans;
29
30
31
32
34
36
37
38
40
44
47
49 trans = FLA_TRANSPOSE;
50
53
54
55
56
57 lwork = -1;
59
60 for (
i = 0;
i < 2; ++
i )
61 {
63 {
64
65
66 if ( datatype == FLA_FLOAT || datatype == FLA_COMPLEX )
67 lwork = ( int ) *FLA_FLOAT_PTR( work );
68 else if ( datatype == FLA_DOUBLE || datatype == FLA_DOUBLE_COMPLEX )
69 lwork = ( int ) *FLA_DOUBLE_PTR( work );
70
73 }
74
75 switch( datatype ){
76
77 case FLA_FLOAT:
78 {
79 float *buff_A = ( float * ) FLA_FLOAT_PTR( A );
80 float *buff_t = ( float * ) FLA_FLOAT_PTR( t );
81 float *buff_B = ( float * ) FLA_FLOAT_PTR( B );
82 float *buff_work = ( float * ) FLA_FLOAT_PTR( work );
83
85 &blas_side,
86 &blas_trans,
87 &m_B,
88 &n_B,
89 &k_t,
90 buff_A, &cs_A,
91 buff_t,
92 buff_B, &cs_B,
93 buff_work, &lwork,
94 &info );
95
96 break;
97 }
98
99 case FLA_DOUBLE:
100 {
101 double *buff_A = ( double * ) FLA_DOUBLE_PTR( A );
102 double *buff_t = ( double * ) FLA_DOUBLE_PTR( t );
103 double *buff_B = ( double * ) FLA_DOUBLE_PTR( B );
104 double *buff_work = ( double * ) FLA_DOUBLE_PTR( work );
105
107 &blas_side,
108 &blas_trans,
109 &m_B,
110 &n_B,
111 &k_t,
112 buff_A, &cs_A,
113 buff_t,
114 buff_B, &cs_B,
115 buff_work, &lwork,
116 &info );
117
118 break;
119 }
120
121 case FLA_COMPLEX:
122 {
127
129 &blas_side,
130 &blas_trans,
131 &m_B,
132 &n_B,
133 &k_t,
134 buff_A, &cs_A,
135 buff_t,
136 buff_B, &cs_B,
137 buff_work, &lwork,
138 &info );
139
140 break;
141 }
142
143 case FLA_DOUBLE_COMPLEX:
144 {
149
151 &blas_side,
152 &blas_trans,
153 &m_B,
154 &n_B,
155 &k_t,
156 buff_A, &cs_A,
157 buff_t,
158 buff_B, &cs_B,
159 buff_work, &lwork,
160 &info );
161
162 break;
163 }
164
165 }
166 }
167
169#else
170 FLA_Check_error_code( FLA_EXTERNAL_LAPACK_NOT_IMPLEMENTED );
171#endif
172
173 return info;
174}
int F77_cunmbr(char *vect, char *side, char *trans, int *m, int *n, int *k, scomplex *a, int *lda, scomplex *tau, scomplex *c, int *ldc, scomplex *work, int *lwork, int *info)
int F77_sormbr(char *vect, char *side, char *trans, int *m, int *n, int *k, float *a, int *lda, float *tau, float *c, int *ldc, float *work, int *lwork, int *info)
int F77_dormbr(char *vect, char *side, char *trans, int *m, int *n, int *k, double *a, int *lda, double *tau, double *c, int *ldc, double *work, int *lwork, int *info)
int F77_zunmbr(char *vect, char *side, char *trans, int *m, int *n, int *k, dcomplex *a, int *lda, dcomplex *tau, dcomplex *c, int *ldc, dcomplex *work, int *lwork, int *info)
dim_t FLA_Obj_width(FLA_Obj obj)
Definition FLA_Query.c:123
FLA_Bool FLA_Obj_is_real(FLA_Obj A)
Definition FLA_Query.c:307
FLA_Error FLA_Obj_create(FLA_Datatype datatype, dim_t m, dim_t n, dim_t rs, dim_t cs, FLA_Obj *obj)
Definition FLA_Obj.c:55
FLA_Bool FLA_Obj_has_zero_dim(FLA_Obj A)
Definition FLA_Query.c:400
dim_t FLA_Obj_length(FLA_Obj obj)
Definition FLA_Query.c:116
dim_t FLA_Obj_col_stride(FLA_Obj obj)
Definition FLA_Query.c:174
void FLA_Param_map_flame_to_netlib_trans(FLA_Trans trans, void *blas_trans)
Definition FLA_Param.c:15
FLA_Error FLA_Obj_free(FLA_Obj *obj)
Definition FLA_Obj.c:588
void FLA_Param_map_flame_to_netlib_side(FLA_Uplo side, void *blas_side)
Definition FLA_Param.c:71
dim_t FLA_Obj_vector_dim(FLA_Obj obj)
Definition FLA_Query.c:137
FLA_Datatype FLA_Obj_datatype(FLA_Obj obj)
Definition FLA_Query.c:13
int FLA_Datatype
Definition FLA_type_defs.h:49
int i
Definition bl1_axmyv2.c:145
Definition FLA_type_defs.h:159
Definition blis_type_defs.h:138
Definition blis_type_defs.h:133