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

Maybe there is an error in Samples/3_CUDA_Features/globalToShmemAsyncCopy/globalToShmemAsyncCopy.cu? #240

Open
xxyux opened this issue Dec 1, 2023 · 0 comments

Comments

@xxyux
Copy link

xxyux commented Dec 1, 2023

As you can see, it shoule be reinterpret_cast<float4 *>(&B[b + wB * threadIdx.y + t4x]); obviously in line721.
However, it is reinterpret_cast<float4 *>(&B[a + wA * threadIdx.y + t4x]);
https://github.com/NVIDIA/cuda-samples/blob/e8568c417356f7e66bb9b7130d6be7e55324a519/Samples/3_CUDA_Features/globalToShmemAsyncCopy/globalToShmemAsyncCopy.cu#L225C1-L225C1

When matrixA.width not equal to matrixB.width, the code will be wrong.

Actually, I don't know what happend.
I just a beginner, and want to know more about cuda::memcpy_async.
Who can answer my question, it really confused me!

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

1 participant