Skip to content

Commit e391dd9

Browse files
For symmetric eigensolvers only upper or lower triangle of a matrix should be set
and remaining part of matrix can contain any values including NaNs but these LAPACKE symmetric eigensolver drivers checked the whole matrix for NaNs and they used transposition of the whole matrix. The new versions check and transpose upper or lower triangle of matrix.
1 parent 86f70bd commit e391dd9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

LAPACKE/src/lapacke_cheev_work.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,15 +70,15 @@ lapack_int LAPACKE_cheev_work( int matrix_layout, char jobz, char uplo,
7070
goto exit_level_0;
7171
}
7272
/* Transpose input matrices */
73-
LAPACKE_cge_trans( matrix_layout, n, n, a, lda, a_t, lda_t );
73+
LAPACKE_che_trans( matrix_layout, uplo, n, a, lda, a_t, lda_t );
7474
/* Call LAPACK function and adjust info */
7575
LAPACK_cheev( &jobz, &uplo, &n, a_t, &lda_t, w, work, &lwork, rwork,
7676
&info );
7777
if( info < 0 ) {
7878
info = info - 1;
7979
}
8080
/* Transpose output matrices */
81-
LAPACKE_cge_trans( LAPACK_COL_MAJOR, n, n, a_t, lda_t, a, lda );
81+
LAPACKE_che_trans( LAPACK_COL_MAJOR, uplo, n, a_t, lda_t, a, lda );
8282
/* Release memory and exit */
8383
LAPACKE_free( a_t );
8484
exit_level_0:

0 commit comments

Comments
 (0)