-
Notifications
You must be signed in to change notification settings - Fork 1
Update Feature: Changed modularity to be during build time. #221
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
Conversation
1377489 to
343e4ec
Compare
|
It should be ready for merge now, you could probably still change "Makefile" now with the changes made to switching between implementations but I haven't done it right now! |
I will take a look! |
GillisC
left a comment
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.
Works well for me, saw a decrease 56,000kb --> 48,000kb in just the size of the test executable. One thing that is needed is to add documentation (remove the old stuff) about how the modularity works in the README, so someone new to the project understands how to compile each target e.t.c.
GillisC
left a comment
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.
LGTM
Description
Changed so that switching between implementation is done during build time with the CMake option -DBUILD=...
It is used like this example:
Example:
src/
--/cuda/
one.cpp
--/default/
one.cpp
two.cpp
include/
one.hpp
two.hpp
Cmake -DBUILD=cuda ..
would use:
src/cuda/one.cpp
src/default/two.cpp
include/one.hpp
include/two.hpp
To follow the same pattern you also add CMake configuration this way by including a CMakeLists.txt with your needed configuration under the implementations like cuda/CmakeLists.txt
Also added a cuda gemm, this was mostly done during my testing but there is no reason to not include it really.
Issue
Closes #220