1 /*
2 
3     Copyright (C) 2014, The University of Texas at Austin
4 
5     This file is part of libflame and is available under the 3-Clause
6     BSD license, which can be found in the LICENSE file at the top-level
7     directory, or at http://opensource.org/licenses/BSD-3-Clause
8 
9 */
10 
11 #include "FLAME.h"
12 
FLA_Sylv_check(FLA_Trans transa,FLA_Trans transb,FLA_Obj isgn,FLA_Obj A,FLA_Obj B,FLA_Obj C,FLA_Obj scale)13 FLA_Error FLA_Sylv_check( FLA_Trans transa, FLA_Trans transb, FLA_Obj isgn, FLA_Obj A, FLA_Obj B, FLA_Obj C, FLA_Obj scale )
14 {
15   FLA_Error e_val;
16 
17   e_val = FLA_Check_valid_blas_trans( transa );
18   FLA_Check_error_code( e_val );
19 
20   e_val = FLA_Check_valid_blas_trans( transb );
21   FLA_Check_error_code( e_val );
22 
23   e_val = FLA_Check_if_scalar( isgn );
24   FLA_Check_error_code( e_val );
25 
26   e_val = FLA_Check_int_object( isgn );
27   FLA_Check_error_code( e_val );
28 
29   e_val = FLA_Check_valid_isgn_value( isgn );
30   FLA_Check_error_code( e_val );
31 
32   e_val = FLA_Check_floating_object( A );
33   FLA_Check_error_code( e_val );
34 
35   e_val = FLA_Check_nonconstant_object( A );
36   FLA_Check_error_code( e_val );
37 
38   e_val = FLA_Check_identical_object_datatype( A, B );
39   FLA_Check_error_code( e_val );
40 
41   e_val = FLA_Check_identical_object_datatype( A, C );
42   FLA_Check_error_code( e_val );
43 
44   e_val = FLA_Check_square( A );
45   FLA_Check_error_code( e_val );
46 
47   e_val = FLA_Check_square( B );
48   FLA_Check_error_code( e_val );
49 
50   e_val = FLA_Check_sylv_matrix_dims( A, B, C );
51   FLA_Check_error_code( e_val );
52 
53   e_val = FLA_Check_if_scalar( scale );
54   FLA_Check_error_code( e_val );
55 
56   e_val = FLA_Check_identical_object_precision( C, scale );
57   FLA_Check_error_code( e_val );
58 
59   return FLA_SUCCESS;
60 }
61 
62