Hi,
I was poking about the existing reduction kernels for #171 . It seems like in reduce.cu and cudalaunch.hpp, the reduction kernels seem to be hard locked to only use a single block (256 threads):
dim3 gridDims(1);
cudaStream_t s0 = getCudaStream();
kernelfunction<<<gridDims, blockDims, 0, s0>>>(args...);
Is this intended/known bug? (Maybe left over from trying to debug the cudamemcpyasyncs?). This would be a pretty large performance penalty for reductions. For something like standardproblem3 or hysteresis which is all minimizes, it's something like ~45%, and probably scales with larger grid sizes. For any dynamic sims, the effect is probably smaller since the FFT kernels will dominate.
(There are some other potential optimizations in terms of things like warp shuffles as well, but that is probably better suited for a PR)
Hi,
I was poking about the existing reduction kernels for #171 . It seems like in reduce.cu and cudalaunch.hpp, the reduction kernels seem to be hard locked to only use a single block (256 threads):
Is this intended/known bug? (Maybe left over from trying to debug the cudamemcpyasyncs?). This would be a pretty large performance penalty for reductions. For something like standardproblem3 or hysteresis which is all minimizes, it's something like ~45%, and probably scales with larger grid sizes. For any dynamic sims, the effect is probably smaller since the FFT kernels will dominate.
(There are some other potential optimizations in terms of things like warp shuffles as well, but that is probably better suited for a PR)