Abstract

Stream compaction, the parallel removal of selected items from a list, is a fundamental building block in parallel algorithms. It is extensively used, both in computer graphics, for shading, collision detection, and ray tracing, as well as in general computing, such as for tree traversal and database selection. In this article, we present Redzone stream compaction, the first parallel stream compaction algorithm to remove k items from a list with n ≥ k elements in O(k) rather than O(n) time. Based on our benchmark experiments on both GPU and CPU, if k is proportionally small ( k ≪ n ), Redzone outperforms existing parallel stream compaction by orders of magnitude, while if k is close to n , it underperforms by a constant factor. Redzone removes items in-place and needs only O(1) auxiliary space. However, unlike current O(n) algorithms, it is unstable (i.e., the order of elements is not preserved) and it needs a list of the items to be removed.

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.