-
Notifications
You must be signed in to change notification settings - Fork 158
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
[SPARSE] Add support for sparse gemv with MKLCPU #374
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did a partial review. Great progress here, @Rbiessy. I'll continue reviewing. Some small changes might be needed for now as a first step.
include/oneapi/mkl/sparse_blas/detail/onemkl_sparse_blas_backends.hxx
Outdated
Show resolved
Hide resolved
include/oneapi/mkl/sparse_blas/detail/onemkl_sparse_blas_backends.hxx
Outdated
Show resolved
Hide resolved
include/oneapi/mkl/sparse_blas/detail/onemkl_sparse_blas_backends.hxx
Outdated
Show resolved
Hide resolved
include/oneapi/mkl/sparse_blas/detail/onemkl_sparse_blas_backends.hxx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did another round of review. It's looking good. I'll still need another round or two!
Made some more changes to follow some spec updates and make it easier to add MKLGPU backend in the future. Please let me know if you have more feedback. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the great work on new domain enabling! I have several questions and suggestions.
include/oneapi/mkl/sparse_blas/detail/onemkl_sparse_blas_backends.hxx
Outdated
Show resolved
Hide resolved
@gajanan-choudhary I am sorry I squashed all the commits and forgot to keep the gemv commit separate. In a nutshell the gemv commit was only calling the MKLCPU |
I have confirmed the tests are still passing locally using 2023.2.0 oneapi package: tests_cpu.txt Following our discussions I have removed the API for |
@@ -144,6 +144,8 @@ $> clang++ -fsycl app.o –L$ONEMKL/lib –lonemkl_blas_mklcpu –lonemkl_blas_c | |||
|
|||
Supported domains: BLAS, LAPACK, RNG, DFT | |||
|
|||
Support for SPARSE_BLAS domain is in progress and disabled by default. Use it at your own risks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mmeterel I think I understand better your concern about adding API that throw unsupported now. If the risk is that users may run into unexpected errors, is adding this line in the README helping?
From my perspective it was more efficient to add all the APIs in one go and the risk of people using it is low given that sparse_blas
is disabled by default.
examples/sparse_blas/compile_time_dispatching/sparse_blas_gemv_usm_mklcpu.cpp
Show resolved
Hide resolved
examples/sparse_blas/compile_time_dispatching/sparse_blas_gemv_usm_mklcpu.cpp
Outdated
Show resolved
Hide resolved
543e55d
to
982db6a
Compare
982db6a
to
cdce00b
Compare
cdce00b
to
1838641
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR is approved from my side, pending the only discussion about header naming (sparse_blas.hpp
versus spblas.hpp
).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, thank you!
Description
This first PR is only adding support for sparse
gemv
and the necessary functions to set it up. This is only adding the MKLCPU backend for now. Compliant with the provisional oneMKL specification v1.3.The operations
trsv
andgemm
are throwing unsupported for now.Note that the examples are based on the oneapi dpcpp examples (like the other domains).
All Submissions
New interfaces
it was accepted? # (RFC)
New features