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

alpaka n-body fixes #823

Merged
merged 2 commits into from
Jan 5, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions examples/alpaka/nbody/nbody.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ struct UpdateKernel
for(int blockOffset = 0; blockOffset < problemSize; blockOffset += SharedElementsPerBlock)
{
for(int j = 0; j < SharedElementsPerBlock; j += ThreadsPerBlock)
sharedView(j) = particles(blockOffset + tbi + j);
sharedView(tbi + j) = particles(blockOffset + tbi + j);
alpaka::syncBlockThreads(acc);
for(int j = 0; j < SharedElementsPerBlock; ++j)
pPInteraction(acc, pis, sharedView(j));
Expand All @@ -231,7 +231,8 @@ struct MoveKernel
};

template<typename Acc>
constexpr auto hasSharedMem = alpaka::accMatchesTags<Acc, alpaka::TagGpuCudaRt, alpaka::TagGpuHipRt>;
constexpr auto hasSharedMem
= alpaka::accMatchesTags<Acc, alpaka::TagGpuCudaRt, alpaka::TagGpuHipRt, alpaka::TagGpuSyclIntel>;

template<typename Acc, Mapping MappingGM, Mapping MappingSM>
void run(std::ostream& plotFile)
Expand Down
Loading