libflame  revision_anchor
Functions | Variables
FLA_Apply_CAQ2_UT_internal.c File Reference

(r)

Functions

FLA_Error FLA_Apply_CAQ2_UT_internal (FLA_Side side, FLA_Trans trans, FLA_Direct direct, FLA_Store storev, FLA_Obj D, FLA_Obj T, FLA_Obj W, FLA_Obj C, FLA_Obj E, fla_apcaq2ut_t *cntl)
 

Variables

fla_apcaq2ut_tflash_apcaq2ut_cntl
 
fla_apcaq2ut_tflash_apcaq2ut_cntl_leaf
 
fla_apcaq2ut_tfla_apcaq2ut_cntl_leaf
 

Function Documentation

◆ FLA_Apply_CAQ2_UT_internal()

FLA_Error FLA_Apply_CAQ2_UT_internal ( FLA_Side  side,
FLA_Trans  trans,
FLA_Direct  direct,
FLA_Store  storev,
FLA_Obj  D,
FLA_Obj  T,
FLA_Obj  W,
FLA_Obj  C,
FLA_Obj  E,
fla_apcaq2ut_t cntl 
)
20 {
21  FLA_Error r_val = FLA_SUCCESS;
22 
23  if ( FLA_Check_error_level() == FLA_FULL_ERROR_CHECKING )
24  FLA_Apply_CAQ2_UT_internal_check( side, trans, direct, storev, D, T, W, C, E, cntl );
25 
26  if ( FLA_Cntl_matrix_type( cntl ) == FLA_HIER &&
27  FLA_Obj_elemtype( D ) == FLA_MATRIX &&
28  FLA_Cntl_variant( cntl ) == FLA_SUBPROBLEM )
29  {
30  // Recurse
31  r_val = FLA_Apply_CAQ2_UT_internal( side,
32  trans,
33  direct,
34  storev,
35  *FLASH_OBJ_PTR_AT( D ),
36  *FLASH_OBJ_PTR_AT( T ),
37  *FLASH_OBJ_PTR_AT( W ),
38  *FLASH_OBJ_PTR_AT( C ),
39  *FLASH_OBJ_PTR_AT( E ),
41  }
42  else if ( FLA_Cntl_matrix_type( cntl ) == FLA_HIER &&
43  FLA_Obj_elemtype( D ) == FLA_SCALAR &&
45  {
46  // Enqueue
47  if ( FLA_Obj_structure( D ) == FLA_FULL_MATRIX )
48  {
49  ENQUEUE_FLASH_Apply_Q2_UT( side, trans, direct, storev, D, T, W, C, E, cntl );
50  }
51  else if ( FLA_Obj_structure( D ) == FLA_UPPER_TRIANGULAR )
52  {
53  ENQUEUE_FLASH_Apply_CAQ2_UT( side, trans, direct, storev, D, T, W, C, E, cntl );
54  }
55  else if ( FLA_Obj_structure( D ) == FLA_ZERO_MATRIX )
56  {
57  // Don't enqueue any tasks for zero blocks.
58  }
59  else
60  {
61  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
62  }
63  }
64  else
65  {
66  if ( FLA_Cntl_matrix_type( cntl ) == FLA_HIER &&
67  FLA_Obj_elemtype( D ) == FLA_SCALAR &&
69  {
70 
71  // Execute leaf.
72  if ( FLA_Obj_structure( D ) == FLA_FULL_MATRIX )
73  {
74  FLA_Apply_Q2_UT_task( side, trans, direct, storev, D, T, W, C, E, NULL );
75  return FLA_SUCCESS;
76  }
77  else if ( FLA_Obj_structure( D ) == FLA_UPPER_TRIANGULAR )
79  else if ( FLA_Obj_structure( D ) == FLA_ZERO_MATRIX )
80  return FLA_SUCCESS;
81  else
82  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
83  }
84 
85  if ( side == FLA_LEFT )
86  {
87  if ( trans == FLA_NO_TRANSPOSE )
88  {
89  if ( direct == FLA_FORWARD )
90  {
91  if ( storev == FLA_COLUMNWISE )
92  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
93  else if ( storev == FLA_ROWWISE )
94  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
95  }
96  else if ( direct == FLA_BACKWARD )
97  {
98  if ( storev == FLA_COLUMNWISE )
99  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
100  else if ( storev == FLA_ROWWISE )
101  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
102  }
103  }
104  else if ( trans == FLA_TRANSPOSE || trans == FLA_CONJ_TRANSPOSE )
105  {
106  if ( direct == FLA_FORWARD )
107  {
108  if ( storev == FLA_COLUMNWISE )
109  r_val = FLA_Apply_CAQ2_UT_lhfc( D, T, W, C, E, cntl );
110  else if ( storev == FLA_ROWWISE )
111  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
112  }
113  else if ( direct == FLA_BACKWARD )
114  {
115  if ( storev == FLA_COLUMNWISE )
116  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
117  else if ( storev == FLA_ROWWISE )
118  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
119  }
120  }
121  }
122  else if ( side == FLA_RIGHT )
123  {
124  if ( trans == FLA_NO_TRANSPOSE )
125  {
126  if ( direct == FLA_FORWARD )
127  {
128  if ( storev == FLA_COLUMNWISE )
129  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
130  else if ( storev == FLA_ROWWISE )
131  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
132  }
133  else if ( direct == FLA_BACKWARD )
134  {
135  if ( storev == FLA_COLUMNWISE )
136  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
137  else if ( storev == FLA_ROWWISE )
138  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
139  }
140  }
141  else if ( trans == FLA_TRANSPOSE || trans == FLA_CONJ_TRANSPOSE )
142  {
143  if ( direct == FLA_FORWARD )
144  {
145  if ( storev == FLA_COLUMNWISE )
146  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
147  else if ( storev == FLA_ROWWISE )
148  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
149  }
150  else if ( direct == FLA_BACKWARD )
151  {
152  if ( storev == FLA_COLUMNWISE )
153  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
154  else if ( storev == FLA_ROWWISE )
155  FLA_Check_error_code( FLA_NOT_YET_IMPLEMENTED );
156  }
157  }
158  }
159  }
160 
161  return r_val;
162 }
FLA_Bool FLASH_Queue_get_enabled(void)
Definition: FLASH_Queue.c:171
FLA_Error FLA_Apply_CAQ2_UT_lhfc(FLA_Obj D, FLA_Obj T, FLA_Obj W, FLA_Obj C, FLA_Obj E, fla_apcaq2ut_t *cntl)
Definition: FLA_Apply_CAQ2_UT_lhfc.c:15
fla_apcaq2ut_t * flash_apcaq2ut_cntl_leaf
Definition: FLASH_Apply_CAQ2_UT_cntl_init.c:13
fla_apcaq2ut_t * fla_apcaq2ut_cntl_leaf
Definition: FLA_Apply_CAQ2_UT_cntl_init.c:19
FLA_Error FLA_Apply_CAQ2_UT_internal(FLA_Side side, FLA_Trans trans, FLA_Direct direct, FLA_Store storev, FLA_Obj D, FLA_Obj T, FLA_Obj W, FLA_Obj C, FLA_Obj E, fla_apcaq2ut_t *cntl)
Definition: FLA_Apply_CAQ2_UT_internal.c:17
FLA_Error FLA_Apply_CAQ2_UT_internal_check(FLA_Side side, FLA_Trans trans, FLA_Direct direct, FLA_Store storev, FLA_Obj D, FLA_Obj T, FLA_Obj W, FLA_Obj C, FLA_Obj E, fla_apcaq2ut_t *cntl)
Definition: FLA_Apply_CAQ2_UT_internal_check.c:13
FLA_Error FLA_Apply_Q2_UT_task(FLA_Side side, FLA_Trans trans, FLA_Direct direct, FLA_Store storev, FLA_Obj D, FLA_Obj T, FLA_Obj W, FLA_Obj C, FLA_Obj E, fla_apq2ut_t *cntl)
Definition: FLA_Apply_Q2_UT_task.c:15
FLA_Elemtype FLA_Obj_elemtype(FLA_Obj obj)
Definition: FLA_Query.c:51
unsigned int FLA_Check_error_level(void)
Definition: FLA_Check.c:18
FLA_Uplo FLA_Obj_structure(FLA_Obj obj)
Definition: FLA_Query.c:130
int FLA_Error
Definition: FLA_type_defs.h:47

References fla_apcaq2ut_cntl_leaf, FLA_Apply_CAQ2_UT_internal(), FLA_Apply_CAQ2_UT_internal_check(), FLA_Apply_CAQ2_UT_lhfc(), FLA_Apply_Q2_UT_task(), FLA_Check_error_level(), FLA_Obj_elemtype(), FLA_Obj_structure(), flash_apcaq2ut_cntl_leaf, and FLASH_Queue_get_enabled().

Referenced by FLA_Apply_CAQ2_UT_internal(), FLA_Apply_CAQ2_UT_lhfc_blk_var2(), FLA_Apply_CAQ2_UT_lhfc_blk_var3(), FLA_Apply_CAQ2_UT_lhfc_task(), FLA_Apply_CAQ2_UT_task(), FLA_Apply_CAQ_UT_inc_lhfc_blk_var1(), and FLA_CAQR_UT_inc_blk_var1().

Variable Documentation

◆ fla_apcaq2ut_cntl_leaf

fla_apcaq2ut_t* fla_apcaq2ut_cntl_leaf
extern

◆ flash_apcaq2ut_cntl

fla_apcaq2ut_t* flash_apcaq2ut_cntl
extern

◆ flash_apcaq2ut_cntl_leaf

fla_apcaq2ut_t* flash_apcaq2ut_cntl_leaf
extern