Microsoft’s analysis division has been laborious at work making an attempt to make ray tracing a extra accessible function for video games of the longer term. A brand new patent from one of many staff’s senior architects describes how the reminiscence and cache load for bounding quantity hierarchies (BVH)— buildings used to hurry up ray tracing—could be diminished through the use of an analogous strategy to texture Degree of Element (LOD) software.
Whereas Microsoft’s Xbox consoles can be the primary beneficiary of this method, AMD’s historically ray tracing weak GPUs, and graphics playing cards that are not blessed with a ton of VRAM are additionally a possible winners.
As with all such patents, the main points inside it are complicated but additionally broad by way of the place they could possibly be used. Its writer, Mark Grossman, is a senior architect in Microsoft’s analysis division, specialising in chip improvement, and he has an extended and distinguished profession in GPUs (beginning with Silicon Graphics, earlier than shifting to ATI Applied sciences, then AMD, and eventually Microsoft).
Final 12 months, he had a patent accredited for decreasing the reminiscence footprint of meshlets, small teams of polygons as utilized in mesh shaders. His newest patent (by way of Tom’s {Hardware}) follows a near-identical format. To hurry up the method of ray tracing, video games use BVH buildings, that are a bit like a flowchart of the volumes that objects in a 3D world take up. BVHs are break up into a big total map, known as a top-level acceleration construction (TLAS), and a number of smaller bottom-level ones (BLAS).
In Cyberpunk 2077, the common dimension of the TLAS is round 15 to 20MB, however the complete BLAS is many instances bigger than this, working into lots of or hundreds of megabytes. In case your graphics card has 16GB or extra of VRAM, it is not likely an issue however you probably have 8GB or much less, then it isn’t laborious to see why it may develop into a problem. And that is very true of consoles with shared reminiscence swimming pools.
Microsoft’s approach avoids utilizing your entire BVH in a single go. As a substitute, small chunks of it are used at a time, and the main points of this utilization and the a part of the BVH in query (known as a node) are saved in two lists within the GPU’s reminiscence. With every successive body, the ray tracing algorithm updates these lists, guaranteeing that solely the nodes required for use within the scene (the remainder simply not being seen or value utilizing) are saved within the VRAM.
Notice that this technique not solely reduces the load on the graphics card’s reminiscence and the GPU’s cache, nevertheless it additionally lowers the quantity of ray tracing checks that must be carried out. Reasonably than having to continuously traverse throughout your entire BVH construction to see what rays are interacting with which objects, solely these within the lists (known as a residency and recording map) must be checked.
That is vital for AMD’s graphics processors as a result of not like Nvidia’s GPUs, they haven’t any devoted {hardware} for accelerating the traversal course of. As a substitute, it is all dealt with by way of compute shaders. Each distributors do have specialised items for testing ray-box and ray-triangle intersections, in order that they each test this stuff off in a short time, however RDNA 2 and newer GPUs spend fairly a little bit of time working by means of the BVH.
So whereas all of this work is to the advantage of the Xbox, it will even be a boon to any gaming PC sporting a Radeon graphics card, powered by a RDNA 2 or RDNA 3 GPU.
Yeah, that is all very sophisticated, and I am nearly actually over-simplifying it, however the one factor that the perfect gaming PCs and consoles have in abundance is compute energy. So it is sensible to leverage one thing that, whereas involving plenty of additional however primary calculations, reduces reminiscence and ray tracing masses.
Though Microsoft’s patent is primarily focused in the direction of enhancing ray tracing efficiency on its Xbox Collection X consoles, the approach could possibly be applied on any platform, as it isn’t particular towards any explicit {hardware}. So you probably have a mainstream graphics card, like a GeForce RTX 4060 or Radeon RX 7600, then you can nicely have the possibility to take pleasure in ray tracing in a sport within the not-too-distant future.