48 #include "control/common.h" 105 MORSE_enum transA, MORSE_enum
diag,
118 printf(
"%d:%s rk:%d maxrk:%d acc:%e alpha:%e\n",
120 rk, maxrk, acc, alpha);
122 MORSE_context_t *morse;
123 MORSE_sequence_t *sequence = NULL;
124 MORSE_request_t request = MORSE_REQUEST_INITIALIZER;
127 morse = morse_context_self();
129 morse_fatal_error(
"MORSE_ztrsm_Tile",
"MORSE not initialized");
130 return MORSE_ERR_NOT_INITIALIZED;
132 morse_sequence_create(morse, &sequence);
137 MORSE_Desc_Flush(
AUV, sequence );
138 MORSE_Desc_Flush( AD, sequence );
139 MORSE_Desc_Flush( Ark, sequence );
140 MORSE_Desc_Flush(
BUV, sequence );
141 MORSE_Desc_Flush( Brk, sequence );
142 morse_sequence_wait(morse, sequence);
149 status = sequence->status;
150 morse_sequence_destroy(morse, sequence);
173 MORSE_enum transA, MORSE_enum
diag,
183 MORSE_sequence_t *sequence, MORSE_request_t *request)
186 printf(
"%d:%s rk:%d maxrk:%d acc:%e alpha:%e\n",
188 rk, maxrk, acc, alpha);
190 MORSE_context_t *morse;
192 morse = morse_context_self();
194 morse_fatal_error(
"MORSE_ztrsm_Tile",
"MORSE not initialized");
195 return MORSE_ERR_NOT_INITIALIZED;
197 if (sequence == NULL) {
198 morse_fatal_error(
"MORSE_ztrsm_Tile",
"NULL sequence");
199 return MORSE_ERR_UNALLOCATED;
201 if (request == NULL) {
202 morse_fatal_error(
"MORSE_ztrsm_Tile",
"NULL request");
203 return MORSE_ERR_UNALLOCATED;
206 if (sequence->status == MORSE_SUCCESS)
207 request->status = MORSE_SUCCESS;
209 return morse_request_fail(sequence, request, MORSE_ERR_SEQUENCE_FLUSHED);
212 if (morse_desc_check(
AUV) != MORSE_SUCCESS) {
213 morse_error(
"MORSE_ztrsm_Tile",
"invalid first descriptor");
214 return morse_request_fail(sequence, request, MORSE_ERR_ILLEGAL_VALUE);
216 if (morse_desc_check(
BUV) != MORSE_SUCCESS) {
217 morse_error(
"MORSE_ztrsm_Tile",
"invalid second descriptor");
218 return morse_request_fail(sequence, request, MORSE_ERR_ILLEGAL_VALUE);
225 if (
side != MorseLeft &&
side != MorseRight) {
226 morse_error(
"MORSE_ztrsm_Tile",
"illegal value of side");
227 return morse_request_fail(sequence, request, -1);
229 if (
uplo != MorseUpper &&
uplo != MorseLower) {
230 morse_error(
"MORSE_ztrsm_Tile",
"illegal value of uplo");
231 return morse_request_fail(sequence, request, -2);
233 if (transA != MorseConjTrans && transA != MorseNoTrans && transA != MorseTrans) {
234 morse_error(
"MORSE_ztrsm_Tile",
"illegal value of transA");
235 return morse_request_fail(sequence, request, -3);
237 if (
diag != MorseUnit &&
diag != MorseNonUnit) {
238 morse_error(
"MORSE_ztrsm_Tile",
"illegal value of diag");
239 return morse_request_fail(sequence, request, -4);
247 return MORSE_SUCCESS;
304 MORSE_enum transA, MORSE_enum
diag,
309 MORSE_desc_t *Bdense,
314 printf(
"%d:%s maxrk:%d alpha:%e\n",
318 MORSE_context_t *morse;
319 MORSE_sequence_t *sequence = NULL;
320 MORSE_request_t request = MORSE_REQUEST_INITIALIZER;
323 morse = morse_context_self();
325 morse_fatal_error(
"MORSE_ztrsmd_Tile",
"MORSE not initialized");
326 return MORSE_ERR_NOT_INITIALIZED;
328 morse_sequence_create(morse, &sequence);
330 AUV, AD, Ark, Bdense,
333 MORSE_Desc_Flush(
AUV, sequence );
334 MORSE_Desc_Flush( AD, sequence );
335 MORSE_Desc_Flush( Ark, sequence );
336 MORSE_Desc_Flush( Bdense, sequence );
337 morse_sequence_wait(morse, sequence);
343 status = sequence->status;
344 morse_sequence_destroy(morse, sequence);
367 MORSE_enum transA, MORSE_enum
diag,
372 MORSE_desc_t *Bdense,
374 MORSE_sequence_t *sequence, MORSE_request_t *request)
377 printf(
"%d:%s maxrk:%d alpha:%e\n",
381 MORSE_context_t *morse;
383 morse = morse_context_self();
385 morse_fatal_error(
"MORSE_ztrsmd_Tile",
"MORSE not initialized");
386 return MORSE_ERR_NOT_INITIALIZED;
388 if (sequence == NULL) {
389 morse_fatal_error(
"MORSE_ztrsmd_Tile",
"NULL sequence");
390 return MORSE_ERR_UNALLOCATED;
392 if (request == NULL) {
393 morse_fatal_error(
"MORSE_ztrsmd_Tile",
"NULL request");
394 return MORSE_ERR_UNALLOCATED;
397 if (sequence->status == MORSE_SUCCESS)
398 request->status = MORSE_SUCCESS;
400 return morse_request_fail(sequence, request, MORSE_ERR_SEQUENCE_FLUSHED);
403 if (morse_desc_check(
AUV) != MORSE_SUCCESS) {
404 morse_error(
"MORSE_ztrsmd_Tile",
"invalid first descriptor");
405 return morse_request_fail(sequence, request, MORSE_ERR_ILLEGAL_VALUE);
407 if (morse_desc_check(Bdense) != MORSE_SUCCESS) {
408 morse_error(
"MORSE_ztrsmd_Tile",
"invalid second descriptor");
409 return morse_request_fail(sequence, request, MORSE_ERR_ILLEGAL_VALUE);
416 if (
side != MorseLeft &&
side != MorseRight) {
417 morse_error(
"MORSE_ztrsmd_Tile",
"illegal value of side");
418 return morse_request_fail(sequence, request, -1);
420 if (
uplo != MorseUpper &&
uplo != MorseLower) {
421 morse_error(
"MORSE_ztrsmd_Tile",
"illegal value of uplo");
422 return morse_request_fail(sequence, request, -2);
424 if (transA != MorseConjTrans && transA != MorseNoTrans && transA != MorseTrans) {
425 morse_error(
"MORSE_ztrsmd_Tile",
"illegal value of transA");
426 return morse_request_fail(sequence, request, -3);
428 if (
diag != MorseUnit &&
diag != MorseNonUnit) {
429 morse_error(
"MORSE_ztrsmd_Tile",
"illegal value of diag");
430 return morse_request_fail(sequence, request, -4);
434 AUV, AD, Ark, Bdense,
438 return MORSE_SUCCESS;
void hicma_pztrsm(MORSE_enum side, MORSE_enum uplo, MORSE_enum trans, MORSE_enum diag, double alpha, MORSE_desc_t *AUV, MORSE_desc_t *AD, MORSE_desc_t *Ark, MORSE_desc_t *BUV, MORSE_desc_t *Brk, int rk, int maxrk, double acc, MORSE_sequence_t *sequence, MORSE_request_t *request)
int HICMA_ztrsm_Tile_Async(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, double alpha, MORSE_desc_t *AUV, MORSE_desc_t *AD, MORSE_desc_t *Ark, MORSE_desc_t *BUV, MORSE_desc_t *Brk, int rk, int maxrk, double acc, MORSE_sequence_t *sequence, MORSE_request_t *request)
int HICMA_ztrsmd_Tile(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, double alpha, MORSE_desc_t *AUV, MORSE_desc_t *AD, MORSE_desc_t *Ark, MORSE_desc_t *Bdense, int maxrk)
int HICMA_ztrsm_Tile(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, double alpha, MORSE_desc_t *AUV, MORSE_desc_t *AD, MORSE_desc_t *Ark, MORSE_desc_t *BUV, MORSE_desc_t *Brk, int rk, int maxrk, double acc)
void hicma_pztrsmd(MORSE_enum side, MORSE_enum uplo, MORSE_enum trans, MORSE_enum diag, double alpha, MORSE_desc_t *AUV, MORSE_desc_t *AD, MORSE_desc_t *Ark, MORSE_desc_t *Bdense, int maxrk, MORSE_sequence_t *sequence, MORSE_request_t *request)
int HICMA_get_print_index()
int HICMA_ztrsmd_Tile_Async(MORSE_enum side, MORSE_enum uplo, MORSE_enum transA, MORSE_enum diag, double alpha, MORSE_desc_t *AUV, MORSE_desc_t *AD, MORSE_desc_t *Ark, MORSE_desc_t *Bdense, int maxrk, MORSE_sequence_t *sequence, MORSE_request_t *request)