oneMKL icon indicating copy to clipboard operation
oneMKL copied to clipboard

Request to implement lapack::gesv

Open npolina4 opened this issue 1 year ago • 3 comments

Summary

Request to implement lapack::gesv for lapack_mklcpu, lapack_mklgpu, and lapack_cusolver library.

Problem statement

I use lapack::gesv to solve a linear matrix equation, or system of linear scalar equations.

Preferred solution

Would be great to have same functionality like onemkl::lapack::gesv from Intel oneAPI.

npolina4 avatar Apr 19 '24 15:04 npolina4

Thanks for the request, @npolina4 ! Please note that lapack::gesv is not yet part of the oneMKL specification (https://github.com/oneapi-src/oneapi-spec), so it would need to be added to the spec before it could be implemented in the oneMKL interfaces. That said, it seems like a useful addition and there are implementations in different vendor libraries (oneapi::mkl::lapack::gesv, cusolverDn??gesv for ?=D/S/Z/C, rocsolver_?gesv for ?=d/s/z/c).

sknepper avatar Apr 19 '24 17:04 sknepper

Can you suggest a workaround that I can use until lapack::gesv is implemented? Thanks

npolina4 avatar Apr 23 '24 18:04 npolina4

Hi @npolina4 ! Yes, lapack::gesv is essentially a higher-level driver that combines LU factorization followed by solve, lapack::getrf and lapack::getrs, into one call. The example https://github.com/oneapi-src/oneMKL/blob/develop/examples/lapack/run_time_dispatching/getrs_usm.cpp demonstrates these two calls.

sknepper avatar Apr 24 '24 04:04 sknepper