libflame revision_anchor
Functions
FLA_Bidiag_unb_external.c File Reference

(r)

Functions

FLA_Error FLA_Bidiag_unb_external (FLA_Obj A, FLA_Obj tu, FLA_Obj tv)
 
FLA_Error FLA_Bidiag_unb_ext (FLA_Obj A, FLA_Obj tu, FLA_Obj tv)
 

Function Documentation

◆ FLA_Bidiag_unb_ext()

FLA_Error FLA_Bidiag_unb_ext ( FLA_Obj  A,
FLA_Obj  tu,
FLA_Obj  tv 
)
146{
147 return FLA_Bidiag_unb_external( A, tu, tv );
148}
FLA_Error FLA_Bidiag_unb_external(FLA_Obj A, FLA_Obj tu, FLA_Obj tv)
Definition FLA_Bidiag_unb_external.c:13
int i
Definition bl1_axmyv2.c:145

References FLA_Bidiag_unb_external(), and i.

◆ FLA_Bidiag_unb_external()

FLA_Error FLA_Bidiag_unb_external ( FLA_Obj  A,
FLA_Obj  tu,
FLA_Obj  tv 
)
14{
15 int info = 0;
16#ifdef FLA_ENABLE_EXTERNAL_LAPACK_INTERFACES
17 FLA_Datatype datatype;
18 int m_A, n_A, cs_A;
19 int min_m_n, max_m_n;
20 int lwork;
21 FLA_Obj d, e, work_obj;
22
25
26 if ( FLA_Obj_has_zero_dim( A ) ) return FLA_SUCCESS;
27
28 datatype = FLA_Obj_datatype( A );
29
30 m_A = FLA_Obj_length( A );
31 n_A = FLA_Obj_width( A );
35
38
39 lwork = max_m_n;
40 FLA_Obj_create( datatype, lwork, 1, 0, 0, &work_obj );
41
42
43 switch( datatype ){
44
45 case FLA_FLOAT:
46 {
47 float* buff_A = ( float * ) FLA_FLOAT_PTR( A );
48 float* buff_d = ( float * ) FLA_FLOAT_PTR( d );
49 float* buff_e = ( float * ) FLA_FLOAT_PTR( e );
50 float* buff_tu = ( float * ) FLA_FLOAT_PTR( tu );
51 float* buff_tv = ( float * ) FLA_FLOAT_PTR( tv );
52 float* buff_work = ( float * ) FLA_FLOAT_PTR( work_obj );
53
55 &n_A,
56 buff_A, &cs_A,
57 buff_d,
58 buff_e,
59 buff_tu,
60 buff_tv,
62 &info );
63
64 break;
65 }
66
67 case FLA_DOUBLE:
68 {
69 double* buff_A = ( double * ) FLA_DOUBLE_PTR( A );
70 double* buff_d = ( double * ) FLA_DOUBLE_PTR( d );
71 double* buff_e = ( double * ) FLA_DOUBLE_PTR( e );
72 double* buff_tu = ( double * ) FLA_DOUBLE_PTR( tu );
73 double* buff_tv = ( double * ) FLA_DOUBLE_PTR( tv );
74 double* buff_work = ( double * ) FLA_DOUBLE_PTR( work_obj );
75
77 &n_A,
78 buff_A, &cs_A,
79 buff_d,
80 buff_e,
81 buff_tu,
82 buff_tv,
84 &info );
85
86 break;
87 }
88
89 case FLA_COMPLEX:
90 {
92 float* buff_d = ( float * ) FLA_FLOAT_PTR( d );
93 float* buff_e = ( float * ) FLA_FLOAT_PTR( e );
97
99 &n_A,
100 buff_A, &cs_A,
101 buff_d,
102 buff_e,
103 buff_tu,
104 buff_tv,
105 buff_work,
106 &info );
107
108 break;
109 }
110
112 {
114 double* buff_d = ( double * ) FLA_DOUBLE_PTR( d );
115 double* buff_e = ( double * ) FLA_DOUBLE_PTR( e );
119
120 F77_zgebd2( &m_A,
121 &n_A,
122 buff_A, &cs_A,
123 buff_d,
124 buff_e,
125 buff_tu,
126 buff_tv,
127 buff_work,
128 &info );
129
130 break;
131 }
132
133 }
134
135 FLA_Obj_free( &d );
136 FLA_Obj_free( &e );
138#else
140#endif
141
142 return info;
143}
FLA_Error FLA_Bidiag_check(FLA_Obj A, FLA_Obj tu, FLA_Obj tv)
Definition FLA_Bidiag_check.c:13
int F77_dgebd2(int *m, int *n, double *a, int *lda, double *d, double *e, double *tauq, double *taup, double *work, int *info)
int F77_cgebd2(int *m, int *n, scomplex *a, int *lda, float *d, float *e, scomplex *tauq, scomplex *taup, scomplex *work, int *info)
int F77_sgebd2(int *m, int *n, float *a, int *lda, float *d, float *e, float *tauq, float *taup, float *work, int *info)
int F77_zgebd2(int *m, int *n, dcomplex *a, int *lda, double *d, double *e, dcomplex *tauq, dcomplex *taup, dcomplex *work, int *info)
dim_t FLA_Obj_width(FLA_Obj obj)
Definition FLA_Query.c:123
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
FLA_Datatype FLA_Obj_datatype_proj_to_real(FLA_Obj A)
Definition FLA_Query.c:23
dim_t FLA_Obj_max_dim(FLA_Obj obj)
Definition FLA_Query.c:160
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
unsigned int FLA_Check_error_level(void)
Definition FLA_Check.c:18
dim_t FLA_Obj_min_dim(FLA_Obj obj)
Definition FLA_Query.c:153
FLA_Error FLA_Obj_free(FLA_Obj *obj)
Definition FLA_Obj.c:588
FLA_Datatype FLA_Obj_datatype(FLA_Obj obj)
Definition FLA_Query.c:13
int FLA_Datatype
Definition FLA_type_defs.h:49
Definition FLA_type_defs.h:159
Definition blis_type_defs.h:138
Definition blis_type_defs.h:133

References F77_cgebd2(), F77_dgebd2(), F77_sgebd2(), F77_zgebd2(), FLA_Bidiag_check(), FLA_Check_error_level(), FLA_Obj_col_stride(), FLA_Obj_create(), FLA_Obj_datatype(), FLA_Obj_datatype_proj_to_real(), FLA_Obj_free(), FLA_Obj_has_zero_dim(), FLA_Obj_length(), FLA_Obj_max_dim(), FLA_Obj_min_dim(), FLA_Obj_width(), and i.

Referenced by FLA_Bidiag_unb_ext().