You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
The current implementation of BlockReduce performs the final aggregation sequentially, executing one load for each warp in the block, i.e. block_size / warp_size. This could become a bottleneck for large block sizes, e.g. 1024 here an example.
A secondary issue is that ApplyWarpAggregates is called recursively with different template parameters, which negatively affects the compile time.
Describe the solution you'd like
Considering that __reduce_sync_op has low latency, comparable to a single shared memory access, it would make sense to evaluate the performance impact of a warp-level reduction in the last step of BlockReduce.
Thanks for assigning this to me. I'm planning to replace the sequential warp aggregate loop in ApplyWarpAggregates with a cooperative warp reduction, using shuffle fallback. Let me know if I'm missing any other details that i need to consider!
Activity
charan-003 commentedon May 18, 2026
Hi @fbusato, I'm interested in working on this optimization if that's okay
fbusato commentedon May 18, 2026
Hi @charan-003, would be amazing. Let me assign the issue to you. Let me know if you need further clarification
charan-003 commentedon May 18, 2026
Thanks for assigning this to me. I'm planning to replace the sequential warp aggregate loop in
ApplyWarpAggregateswith a cooperative warp reduction, using shuffle fallback. Let me know if I'm missing any other details that i need to consider!