Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.
Announcements
This community is designed for sharing of public information. Please do not share Intel or third-party confidential information here.

bug in cblas_sscal ( ) ?

Customer__Intel4
Beginner
155 Views
Hi
I discovered that when usingcblas_sscal ( ) to scale an array to zero values, sometimes ( not every time) an entry of the array after scaling becomes nan. The command simply reads:cblas_sscal(L, 0.0, A, 1); where L is the length of the array A.
0 Kudos
3 Replies
TimP
Black Belt
155 Views
cblas_sscal() requires a float constant. If you have a correct prototype in scope (by the supplied include files), the compiler would take care of cast from the double value you supplied.
Chao_Y_Intel
Employee
155 Views

Hi,
If input the data type is no problem, it needs a test code that could show thi problem. Feel free to post here if you have.

Thanks,
Chao

Murat_G_Intel
Employee
155 Views
If your input array A contains NaNs, then scaling a NaN value with 0.0 will still give a NaN.
Reply