add NaN check for input scalars s and c to lapacke_crot and lapacke_srot

This commit is contained in:
Julien Langou
2026-03-24 14:18:29 -06:00
parent 10d120966e
commit 8fa1db366b
2 changed files with 12 additions and 0 deletions
+6
View File
@@ -46,6 +46,12 @@ lapack_int API_SUFFIX(LAPACKE_crot)( lapack_int n,
if( API_SUFFIX(LAPACKE_c_nancheck)( n, cy, incy ) ) {
return -4;
}
if( API_SUFFIX(LAPACKE_s_nancheck)( 1, c, 1 ) ) {
return -6;
}
if( API_SUFFIX(LAPACKE_c_nancheck)( 1, s, 1 ) ) {
return -7;
}
}
#endif
return API_SUFFIX(LAPACKE_crot_work)( n, cx, incx, cy, incy, c, s );
+6
View File
@@ -46,6 +46,12 @@ lapack_int API_SUFFIX(LAPACKE_zrot)( lapack_int n,
if( API_SUFFIX(LAPACKE_z_nancheck)( n, cy, incy ) ) {
return -4;
}
if( API_SUFFIX(LAPACKE_d_nancheck)( 1, c, 1 ) ) {
return -6;
}
if( API_SUFFIX(LAPACKE_z_nancheck)( 1, s, 1 ) ) {
return -7;
}
}
#endif
return API_SUFFIX(LAPACKE_zrot_work)( n, cx, incx, cy, incy, c, s );