Skip to content
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

Link error when call "GemmStridedBatched<cl_float2>" #551

Open
diverger opened this issue Jul 9, 2024 · 1 comment
Open

Link error when call "GemmStridedBatched<cl_float2>" #551

diverger opened this issue Jul 9, 2024 · 1 comment
Labels

Comments

@diverger
Copy link

diverger commented Jul 9, 2024

Hi,
I need to do complex matrix multiplication, but when I specialize the template function with "cl_float2", it passed compilation, but failed when link. The compiler complain:

undefined reference to `clblast::StatusCode clblast::GemmStridedBatched<cl_float2>....................

So, I guess this function doesn't support complex, or it's a bug.

@CNugteren
Copy link
Owner

It should be supported, see the docs. There is also a C version of the function. And the C++ version is compiled here. I guess the issue is that you are using cl_float2 whereas CLBlast uses the C++ data-type std::complex<float>; instead. You can keep your OpenCL buffers of type cl_float2, but the template argument and the value of the alpha and beta parameters should be C++ type, not the OpenCL type.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants