Skip to content

Commit 742f54c

Browse files
authored
Merge pull request #1303 from martin-frbg/imatcopy-rowscols
Fix cols/rows mixup in omatcopy 2nd step for BlasTrans cases
2 parents 2922c15 + d674fbb commit 742f54c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

interface/imatcopy.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ void CNAME( enum CBLAS_ORDER CORDER, enum CBLAS_TRANSPOSE CTRANS, blasint crows,
121121
return;
122122
}
123123
#ifdef NEW_IMATCOPY
124-
if ( *lda == *ldb && *cols == *rows ) {
124+
if ( *lda == *ldb && *rows == *cols) {
125125
if ( order == BlasColMajor )
126126
{
127127
if ( trans == BlasNoTrans )
@@ -171,7 +171,7 @@ void CNAME( enum CBLAS_ORDER CORDER, enum CBLAS_TRANSPOSE CTRANS, blasint crows,
171171
else
172172
{
173173
OMATCOPY_K_CT(*rows, *cols, *alpha, a, *lda, b, *ldb );
174-
OMATCOPY_K_CN(*rows, *cols, (FLOAT) 1.0, b, *ldb, a, *ldb );
174+
OMATCOPY_K_CN(*cols, *rows, (FLOAT) 1.0, b, *ldb, a, *ldb );
175175
}
176176
}
177177
else
@@ -184,7 +184,7 @@ void CNAME( enum CBLAS_ORDER CORDER, enum CBLAS_TRANSPOSE CTRANS, blasint crows,
184184
else
185185
{
186186
OMATCOPY_K_RT(*rows, *cols, *alpha, a, *lda, b, *ldb );
187-
OMATCOPY_K_RN(*rows, *cols, (FLOAT) 1.0, b, *ldb, a, *ldb );
187+
OMATCOPY_K_RN(*cols, *rows, (FLOAT) 1.0, b, *ldb, a, *ldb );
188188
}
189189
}
190190

0 commit comments

Comments
 (0)