How BVH Building in Ray Tracing Benchmarks Stresses the CPU

This article explores how building Bounding Volume Hierarchy (BVH) acceleration structures for hardware ray tracing places an intense workload on the CPU during hardware benchmarks. While ray tracing is traditionally viewed as a graphics card test, the processor plays a critical role in organizing 3D scene data, managing system memory, and issuing complex rendering commands before the GPU can trace a single ray. Understanding the mechanics of BVH construction explains why modern ray tracing benchmarks are a definitive test of a CPU's multi-threading capabilities, cache hierarchy, and memory bandwidth.

Understanding the Bounding Volume Hierarchy (BVH)

To render a ray-traced scene efficiently, hardware cannot test every light ray against every individual triangle in a 3D environment, as this would require billions of calculations per frame. Instead, the system uses an acceleration structure called a Bounding Volume Hierarchy (BVH).

A BVH organizes the 3D scene into a tree-like structure of nested, invisible boxes that encompass the geometry. When a ray is cast, the hardware checks if it hits the largest outer box. If it misses, it ignores everything inside that box. If it hits, it checks the smaller boxes inside until it finds the exact triangle the ray intersects.

The CPU’s Role in BVH Construction

In modern rendering APIs like DirectX 12 and Vulkan, the GPU often handles the final mathematical assembly of the BVH. However, the CPU is entirely responsible for preparing the scene data and orchestrating the build process. In dedicated CPU-focused benchmarks, the processor builds the entire tree structure itself. In both scenarios, the CPU faces a massive computational workload that happens every single frame.

1. Dynamic Geometry Updates

In a static scene, a BVH only needs to be built once. However, benchmarks simulate complex gaming and rendering environments featuring moving characters, explosions, and destructible objects. Whenever an object moves or deforms, the BVH becomes invalid. The CPU must calculate the new positions, process animations, and instruct the system to either "refit" (adjust) the existing BVH boxes or completely rebuild the tree from scratch. Doing this at 60 to 120+ times per second puts immense continuous pressure on the processor.

2. Extreme Multi-Threading Saturation

Preparing and building a BVH requires sorting millions of polygons in 3D space. Because different branches of the BVH tree can be calculated independently, this workload is highly parallelizable. Benchmarks utilize this by spreading the BVH tasks across all available CPU cores and threads. A processor with weak multi-threading performance or poor thread scheduling will bottleneck the entire system, leaving the GPU waiting for data.

3. Cache and Memory Bandwidth Bottlenecks

Constructing a spatial tree structure is not just a math problem; it is a data-sorting problem. The CPU must rapidly read the coordinates of millions of vertices, sort them spatially, and write the resulting hierarchy back to system memory.

This process jumps erratically through memory addresses, which frequently causes "cache misses"—situations where the data the CPU needs is not in its ultra-fast L1, L2, or L3 cache. Consequently, the CPU must fetch data from the much slower system RAM. Ray tracing benchmarks heavily stress the CPU’s memory controller and expose latencies in the system's RAM and cache architecture.

4. Increased Draw Calls and API Overhead

In traditional rasterization, the CPU only needs to process objects that are directly inside the camera's field of view. In a ray tracing benchmark, objects behind the camera or around corners must still be processed by the CPU because they might appear in reflections, cast shadows, or bounce light into the scene.

Because the entire 3D environment must be kept active in the BVH, the CPU has to track vastly more objects simultaneously. It must allocate memory, manage states, and generate massive command lists for the GPU. This multiplies the API overhead, pushing the CPU's single-core instruction-per-clock (IPC) performance to its limits alongside its multi-core capabilities.

Why This Matters in Hardware Benchmarking

When reviewers and engineers use ray tracing benchmarks to test computer hardware, the BVH build process serves as a worst-case scenario for the CPU. It moves the processor away from simple, predictable linear workloads and forces it to handle chaotic memory access patterns, massive data transfers, and heavy thread synchronization. If a CPU can maintain high frame rates during the BVH construction phase of a ray tracing benchmark, it proves the processor has the cache capacity, core count, and architectural efficiency required for next-generation workloads.