Parallel k-d Tree Construction on GPU Using Radix Sorting
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing methods for constructing bounding volume hierarchies (BVHs), k-d trees, and octrees are limited by sequential processing, which underutilizes parallel cores and results in suboptimal performance, especially on GPUs with many independent threads, and often output in breadth-first order rather than the preferred depth-first order.
Innovation Solution
A method for constructing these trees in a fully parallel fashion using binary radix trees, where internal nodes are built in parallel with ancestor nodes, requiring only a linear amount of temporary storage, and Morton codes are used to sort primitives and build trees efficiently, allowing for depth-first ordering and maximizing GPU performance.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If sequential processing is used to construct tree hierarchies, then the construction process is simple to implement, but the parallel cores are severely underutilized and performance does not scale with the number of cores
Solution Approach 1:
The patent divides the tree construction process into independent segments by assigning different tree levels to different thread blocks. Each thread block constructs a specific level of the tree hierarchy independently, allowing full utilization of parallel cores without complex inter-block synchronization.
Solution Approach 2:
The patent transitions from sequential level-by-level construction to parallel level-agnostic construction. By reordering the construction process to operate on different levels simultaneously rather than sequentially, the system achieves linear scalability with the number of parallel cores while maintaining simplicity through the use of global memory operations.
2Ease of operation
If sequential level-by-level processing is used, then the implementation is straightforward, but the output order is breadth-first instead of the preferred depth-first order
Solution Approach 1:
The patent inverts the conventional breadth-first construction approach by constructing tree levels in parallel without following the traditional level-order sequence. By allowing threads to construct different levels simultaneously and using global memory operations to collect results, the system achieves the desired depth-first output order while maintaining implementation simplicity through the parallel radix tree construction algorithm.
3Productivity
If more parallel threads are used to utilize GPU computing power, then construction speed increases, but the complexity of coordinating thread execution increases
Solution Approach 1:
The patent segments the construction workload by assigning different tree levels to different thread blocks, allowing each block to operate independently with its own set of threads. This segmentation eliminates the need for complex thread coordination while enabling full utilization of GPU computing power through parallel construction of multiple tree levels simultaneously.
Data Source
AI summary
A non-transitory computer-readable storage medium having computer-executable instructions for causing a computer system to perform a method for constructing k-d trees, octrees, and quadtrees from radix trees is disclosed. The method includes assigning a Morton code for each of a plurality of primitives corresponding to leaf nodes of a binary radix tree, and sorting the plurality of Morton codes. The method includes building a radix tree requiring at most a linear amount of temporary storage with respect to the leaf nodes, wherein an internal node is built in parallel with one or more of its ancestor nodes. The method includes, partitioning the plurality of Morton codes for each node of the radix tree into categories based on a corresponding highest differing bit to build a k-d tree. A number of octree or quadtree nodes is determined for each node of the k-d tree. A total number of nodes in the octree or quadtree is determined, allocated and output.


