intel/compiler: Add support for ray-tracing
This merge request adds ray-tracing support to the Intel shader compiler in Mesa. This is the first instalment of many to add ray-tracing support to the Intel Linux Vulkan driver. This MR is based on top of !6479 (merged) which adds SPIR-V support for ray-tracing.
At a high-level, this MR contains the following:
- A new
gen_device_info::has_ray_tracingflag to delimit platforms with ray-tracing support
- GenXML representations of various ray-tracing data structures
- Back-end compiler support for the new bindless thread dispatch (BTD) model on top of which Intel's ray-tracing implementation is built
- Back-end compiler support for the new ray traversal hardware (closely related to the BTD hardware)
- Lots of NIR code for lowering the high-level ray-tracing concepts in the Vulkan ray-tracing API to bindless shaders.
While obviously not everything required for ray-tracing, this is a good chunk. These patches have been fairly stable for some time now and are working well. (I have only 3 undiagnosed potentially compiler-related CTS failures.) I'd like to get these merged upstream and start shrinking the internal patch pile.
Notably not included in this MR are:
- Platform support for a platform which has ray-tracing
- Vulkan driver code for compiling ray-tracing pipelines
- Vulkan driver code for managing acceleration structures
- Vulkan driver code for dispatching rays
Those will all be coming in due course. Vulkan Ray-tracing is basically a whole new 3D rendering API so there are a lot of pieces. The driver patches are in a somewhat annoying spot right now because they're based on the latest version of the Vulkan ray-tracing API which isn't public yet. I could rebase them on the provisional API from January but then we'd have to deal with fixing them up once the final API gets released. They're also entirely internal to the driver and don't break every time @anholt decides to rework liveness analysis in NIR.