libflame revision_anchor
Functions
FLA_Trmm_external_gpu.c File Reference

(r)

Functions

FLA_Error FLA_Trmm_external_gpu (FLA_Side side, FLA_Uplo uplo, FLA_Trans trans, FLA_Diag diag, FLA_Obj alpha, FLA_Obj A, void *A_gpu, FLA_Obj B, void *B_gpu)
 

Function Documentation

◆ FLA_Trmm_external_gpu()

FLA_Error FLA_Trmm_external_gpu ( FLA_Side  side,
FLA_Uplo  uplo,
FLA_Trans  trans,
FLA_Diag  diag,
FLA_Obj  alpha,
FLA_Obj  A,
void A_gpu,
FLA_Obj  B,
void B_gpu 
)
18{
19 FLA_Datatype datatype;
20 int m_B, n_B;
21 int ldim_A;
22 int ldim_B;
23 char blas_side;
24 char blas_uplo;
25 char blas_trans;
26 char blas_diag;
27
29 FLA_Trmm_check( side, uplo, trans, diag, alpha, A, B );
30
31 if ( FLA_Obj_has_zero_dim( B ) ) return FLA_SUCCESS;
32
33 datatype = FLA_Obj_datatype( A );
34
36
37 m_B = FLA_Obj_length( B );
38 n_B = FLA_Obj_width( B );
40
45
46
47 switch( datatype ){
48
49 case FLA_FLOAT:
50 {
51 float *buff_alpha = ( float * ) FLA_FLOAT_PTR( alpha );
52
54 blas_uplo,
57 m_B,
58 n_B,
60 ( float * ) A_gpu, ldim_A,
61 ( float * ) B_gpu, ldim_B );
62
63 break;
64 }
65
66 case FLA_DOUBLE:
67 {
68 double *buff_alpha = ( double * ) FLA_DOUBLE_PTR( alpha );
69
71 blas_uplo,
74 m_B,
75 n_B,
77 ( double * ) A_gpu, ldim_A,
78 ( double * ) B_gpu, ldim_B );
79
80 break;
81 }
82
83 case FLA_COMPLEX:
84 {
86
88 blas_uplo,
91 m_B,
92 n_B,
94 ( cuComplex * ) A_gpu, ldim_A,
95 ( cuComplex * ) B_gpu, ldim_B );
96
97 break;
98 }
99
101 {
103
105 blas_uplo,
107 blas_diag,
108 m_B,
109 n_B,
110 *buff_alpha,
113
114 break;
115 }
116
117 }
118
119 return FLA_SUCCESS;
120}
FLA_Error FLA_Trmm_check(FLA_Side side, FLA_Uplo uplo, FLA_Trans trans, FLA_Diag diag, FLA_Obj alpha, FLA_Obj A, FLA_Obj B)
Definition FLA_Trmm_check.c:13
void FLA_Param_map_flame_to_netlib_diag(FLA_Diag diag, void *blas_diag)
Definition FLA_Param.c:95
dim_t FLA_Obj_width(FLA_Obj obj)
Definition FLA_Query.c:123
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
unsigned int FLA_Check_error_level(void)
Definition FLA_Check.c:18
void FLA_Param_map_flame_to_netlib_trans(FLA_Trans trans, void *blas_trans)
Definition FLA_Param.c:15
void FLA_Param_map_flame_to_netlib_side(FLA_Uplo side, void *blas_side)
Definition FLA_Param.c:71
void FLA_Param_map_flame_to_netlib_uplo(FLA_Uplo uplo, void *blas_uplo)
Definition FLA_Param.c:47
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

References FLA_Check_error_level(), FLA_Obj_datatype(), FLA_Obj_has_zero_dim(), FLA_Obj_length(), FLA_Obj_width(), FLA_Param_map_flame_to_netlib_diag(), FLA_Param_map_flame_to_netlib_side(), FLA_Param_map_flame_to_netlib_trans(), FLA_Param_map_flame_to_netlib_uplo(), FLA_Trmm_check(), and i.

Referenced by FLASH_Queue_exec_task_gpu().