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

Add support for GPU in CMake buildsystem #162

Open
traversaro opened this issue Jun 6, 2021 · 3 comments
Open

Add support for GPU in CMake buildsystem #162

traversaro opened this issue Jun 6, 2021 · 3 comments

Comments

@traversaro
Copy link

#161 added a CMake-based buildsystem, but at the moment the GPU builds are not supported there. It would be convenient to modify it to support also GPU builds. I plan to work on this as part of conda-forge/scs-feedstock#18, this is just a placeholder issue to make sure that anyone interested is aware of this.

@traversaro
Copy link
Author

I am definitely not an expert in this, but given that apparently this is just a C library that links CUDA libraries, it should be sufficient to use https://cmake.org/cmake/help/latest/module/FindCUDAToolkit.html . If instead the library contained .cu files, we should have enabled the CUDA language, see https://cliutils.gitlab.io/modern-cmake/chapters/packages/CUDA.html .

@h-vetinari
Copy link

Hello @bodono, happy new year! :)

Could we come back to this issue?

I'd add that it might be a good idea to consider moving the reference build system to CMake completely - it's just much more portable than a Makefile; otherwise it's a constant battle to keep them in sync resp. working equivalently.

@bodono
Copy link
Member

bodono commented Jan 6, 2023

On the GPU stuff - the GPU code is still broken in some way that I haven't had time to track down. Overall the GPU doesn't provide much benefit anyway and users are probably better off using MKL (if they can).

I agree that CMake is better than Make overall. Unfortunately I don't know much about CMake, and I didn't contribute the original CMake code to SCS. I'd be happy to accept a PR that removes the Makefile and cleans up the CMake file if anyone is able to help!

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

No branches or pull requests

3 participants