-
Notifications
You must be signed in to change notification settings - Fork 119
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
Hadar/base math #734
Hadar/base math #734
Conversation
@@ -37,6 +39,12 @@ | |||
|
|||
using namespace icicle; | |||
|
|||
#ifdef __CUDA_ARCH__ | |||
namespace base_math = device_math; | |||
#else |
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.
We should be able to extend this to Metal and Vulkan as well
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.
yes, probably
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.
but metal and vulkan are separate shaders, not sharing this code
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.
@yshekel I meant the namespace
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.
I assume no performance impact right?
This PR separates cpu (host) math and gpu (device) math from the field class itself. Now the field calls the relevant base math according to the context.
CUDA backend branch
cuda-backend-branch: hadar/base-math