| 
35 | 35 | *>  | 
36 | 36 | *> alpha and beta are scalars, and A, B and C are matrices, with op( A )  | 
37 | 37 | *> an m by k matrix,  op( B )  a  k by n matrix and  C an m by n matrix.  | 
 | 38 | +*>  | 
 | 39 | +*> Note: if alpha and/or beta is zero, some parts of the matrix-matrix  | 
 | 40 | +*>  operations are not performed. This results in the following NaN/Inf  | 
 | 41 | +*>  propagation quirks:  | 
 | 42 | +*>  | 
 | 43 | +*>  1. If alpha is zero, NaNs or Infs in A or B do not affect the result.  | 
 | 44 | +*>  2. If both alpha and beta are zero, then a zero matrix is returned in C,  | 
 | 45 | +*>   irrespective of any NaNs or Infs in A, B or C.  | 
 | 46 | +*>  3. If only beta is zero, alpha*op( A )*op( B ) is returned, irrespective  | 
 | 47 | +*>   of any NaNs or Infs in C.  | 
38 | 48 | *> \endverbatim  | 
39 | 49 | *  | 
40 | 50 | *  Arguments:  | 
 | 
92 | 102 | *> \param[in] ALPHA  | 
93 | 103 | *> \verbatim  | 
94 | 104 | *>          ALPHA is COMPLEX  | 
95 |  | -*>           On entry, ALPHA specifies the scalar alpha.  | 
 | 105 | +*>           On entry, ALPHA specifies the scalar alpha. If ALPHA is zero the  | 
 | 106 | +*>           values in A and B do not affect the result. This also means that  | 
 | 107 | +*>           NaN/Inf propagation from A and B is inhibited if ALPHA is zero.  | 
96 | 108 | *> \endverbatim  | 
97 | 109 | *>  | 
98 | 110 | *> \param[in] A  | 
 | 
102 | 114 | *>           Before entry with  TRANSA = 'N' or 'n',  the leading  m by k  | 
103 | 115 | *>           part of the array  A  must contain the matrix  A,  otherwise  | 
104 | 116 | *>           the leading  k by m  part of the array  A  must contain  the  | 
105 |  | -*>           matrix A.  | 
 | 117 | +*>           matrix A, except if ALPHA is zero.  | 
 | 118 | +*>           If ALPHA is zero, none of the values in A affect the result, even  | 
 | 119 | +*>           if they are NaN/Inf. This also implies that if ALPHA is zero,  | 
 | 120 | +*>           the matrix elements of A need not be initialized by the caller.  | 
106 | 121 | *> \endverbatim  | 
107 | 122 | *>  | 
108 | 123 | *> \param[in] LDA  | 
 | 
121 | 136 | *>           Before entry with  TRANSB = 'N' or 'n',  the leading  k by n  | 
122 | 137 | *>           part of the array  B  must contain the matrix  B,  otherwise  | 
123 | 138 | *>           the leading  n by k  part of the array  B  must contain  the  | 
124 |  | -*>           matrix B.  | 
 | 139 | +*>           matrix B, except if ALPHA is zero.  | 
 | 140 | +*>           If ALPHA is zero, none of the values in B affect the result, even  | 
 | 141 | +*>           if they are NaN/Inf. This also implies that if ALPHA is zero,  | 
 | 142 | +*>           the matrix elements of B need not be initialized by the caller.  | 
125 | 143 | *> \endverbatim  | 
126 | 144 | *>  | 
127 | 145 | *> \param[in] LDB  | 
 | 
136 | 154 | *> \param[in] BETA  | 
137 | 155 | *> \verbatim  | 
138 | 156 | *>          BETA is COMPLEX  | 
139 |  | -*>           On entry,  BETA  specifies the scalar  beta.  When  BETA  is  | 
140 |  | -*>           supplied as zero then C need not be set on input.  | 
 | 157 | +*>           On entry,  BETA  specifies the scalar  beta. If BETA is zero the  | 
 | 158 | +*>           values in C do not affect the result. This also means that  | 
 | 159 | +*>           NaN/Inf propagation from C is inhibited if BETA is zero.  | 
141 | 160 | *> \endverbatim  | 
142 | 161 | *>  | 
143 | 162 | *> \param[in,out] C  | 
144 | 163 | *> \verbatim  | 
145 | 164 | *>          C is COMPLEX array, dimension ( LDC, N )  | 
146 | 165 | *>           Before entry, the leading  m by n  part of the array  C must  | 
147 |  | -*>           contain the matrix  C,  except when  beta  is zero, in which  | 
148 |  | -*>           case C need not be set on entry.  | 
 | 166 | +*>           contain the matrix  C, except if beta is zero.  | 
 | 167 | +*>           If beta is zero, none of the values in C affect the result, even  | 
 | 168 | +*>           if they are NaN/Inf. This also implies that if beta is zero,  | 
 | 169 | +*>           the matrix elements of C need not be initialized by the caller.  | 
149 | 170 | *>           On exit, the array  C  is overwritten by the  m by n  matrix  | 
150 | 171 | *>           ( alpha*op( A )*op( B ) + beta*C ).  | 
151 | 172 | *> \endverbatim  | 
 | 
185 | 206 | *  =====================================================================  | 
186 | 207 |       SUBROUTINE CGEMM(TRANSA,TRANSB,M,N,K,ALPHA,A,LDA,B,LDB,  | 
187 | 208 |      +         BETA,C,LDC)  | 
 | 209 | +      IMPLICIT NONE  | 
188 | 210 | *  | 
189 | 211 | *  -- Reference BLAS level3 routine --  | 
190 | 212 | *  -- Reference BLAS is a software package provided by Univ. of Tennessee,    --  | 
 | 
0 commit comments