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

Pull out conv2d kernels from op #320

Merged
merged 15 commits into from
Dec 12, 2022
Merged

Conversation

lockshaw
Copy link
Collaborator

By pulling out the kernel functions into their own files, we should decrease build time by reducing the number of times the kernels (which rarely change) need to be recompiled

src/ops/conv_2d.cc Outdated Show resolved Hide resolved
Copy link
Collaborator

@reyna-abhyankar reyna-abhyankar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, it looks good to me. I have one question that's related to the codebase. The .cpp file seem to mimic its corresponding .cu file. Is it auto-generated? If not, should that also be modified for this PR?

Also, what is the purpose of the kernel wrappers? If there's a forward and a backward and then also have forward_kernel and backward_kernel, I'm wondering if the wrapper is really necessary because it mostly seems to be doing some profiling.

@lockshaw
Copy link
Collaborator Author

Blocked on #345 as currently I can't check that the AMD kernel changes are correct

@lockshaw lockshaw linked an issue Nov 8, 2022 that may be closed by this pull request
@lockshaw lockshaw enabled auto-merge (squash) December 11, 2022 10:00
@lockshaw lockshaw merged commit ebe4488 into flexflow:master Dec 12, 2022
Copy link
Collaborator

@reyna-abhyankar reyna-abhyankar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the purpose of the change from typename to class in model.h? Otherwise LGTM

@lockshaw
Copy link
Collaborator Author

What is the purpose of the change from typename to class in model.h? Otherwise LGTM

This is a C++17 feature apparently 🤷, whereas class is C++11 compliant. C++11 compliance checking is being added #271

@lockshaw lockshaw deleted the re/conv2d-kernels branch July 17, 2023 17:49
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

Successfully merging this pull request may close these issues.

Kernel refactor for Conv2D
4 participants