-
Notifications
You must be signed in to change notification settings - Fork 155
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
oneapi::mkl::lapack::getrf pivot vectors are wrong #79
Comments
Thank you for the detailed bug report, including a reproducer! This project doesn't cover oneMKL binary product and the better way to escalate issues is the oneMKL Forum. You can read more about difference between oneMKL interfaces project and Intel oneMKL release here. That said, the Intel oneMKL team will take a look at this issue now that you've brought it to our attention. Thanks! |
We took a look, and it seems like the link line may be incorrect. Please consider using the Link Line Advisor to configure the link command according to your program features. In particular, Intel® oneAPI Math Kernel Library for DPC++ only supports using the mkl_intel_ilp64 interface library. Linking with the mkl_intel_ilp64 interface library and defining the compilation option -DMKL_ILP64 allow the program to run with the expected behavior: While linking to the mkl_intel_lp64 interface library resulted in the same output you reported. Example link line: Thanks, and please let us know if this doesn't solve the issue. |
Hi. Thank you. That does indeed solve the issue. |
I'm sorry I didn't show my link line in the original post. In other parts of my code I use the original 32 bit fortran BLAS and LAPACK interfaces directly. I wonder how I will be able to combine both these 32 bit interfaces and the 64 bit oneAPI interfaces in a single library. |
Hi @pghysels, so far it's not possible, but we will investigate how we can enable mixing of lp64/ilp64 APIs in one library. Is it important to have 32 bit fortran API in your application? |
The 32 bit Fortran interface is used extensively in our code. I could refactor this to make the BLAS/LAPACK integer size a template parameter or make it configurable at compile time. But this would require considerable changes. We didn't think we would ever need 64 bit LAPACK. |
Thanks @pghysels, I will keep this issue updated with any information about enabling lp64/ilp64 mixing support in Intel oneMKL. |
Summary
The oneapi::mkl::lapack::getrf routine takes a std::int64_t pointer for the pivots.
But the output for the pivots seems wrong. It looks like they are generated as 32 bit numbers.
The corresponding getrs code works with the output from oneapi::mkl::lapack::getrf.
Version
oneapi/2020.12.15.005
Environment
Steps to reproduce
Observed behavior
Output of above code:
8589934593 17179869187 25769803781 34359738375 42949672969 0 0 0 0 0
1 2 3 4 5 6 7 8 9 10
Expected behavior
Document behavior you expect.
1 2 3 4 5 6 7 8 9 10
The text was updated successfully, but these errors were encountered: