-
Notifications
You must be signed in to change notification settings - Fork 13.7k
Add Pad Reflect 1D CUDA support #14659
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 Pad Reflect 1D CUDA support #14659
Conversation
JohannesGaessler
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.
Please tell me whether you want to address the comment regarding the loop in this PR.
| const char * src0_ptr = (const char *)src0 + i3*nb03 + i2*nb02 + i1*nb01; | ||
| char * dst_ptr = (char *)dst + i3*nb3 + i2*nb2 + i1*nb1; | ||
|
|
||
| for (int64_t i0 = threadIdx.x; i0 < ne0; i0 += blockDim.x) { |
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.
This is going to produce correct results but generally speaking you will get much better performance if each thread just works on a single value instead of looping over ne0. However, it would also be fine to just merge it as-is and maybe change this later if it ever becomes relevant for end-to-end performance.
Co-authored-by: Johannes Gäßler <[email protected]>
|
@YavorGIvanov Shall we merge as-is or are you looking into the review comment by @JohannesGaessler? |
|
@YavorGIvanov ping |
|
Let's merge as is. @CISC |
* Add Pad Reflect 1D CUDA support * Update ggml/src/ggml-cuda/pad_reflect_1d.cu Co-authored-by: Johannes Gäßler <[email protected]> --------- Co-authored-by: Johannes Gäßler <[email protected]>
No description provided.