The validation error is bogus I think. The spec says that pStages[] arrays are implicitly added to by using pipeline libraries, and that additional shader is referenced by a pGroup entry.
Thanks, that makes sense. The spec doesn’t exactly make it obvious. I opened a PR on the validation layers.
VKD3D_CONFIG=dxrx1 2021-09VKD3D_TEST_FILTER=raytracingx1 2021-09
Hi,
I’m not that familiar with the dxr and vulkan raytracing APIs, so I’m not sure if this is an issue in the raytracing test, vkd3d or the driver, but my guess is this is a problem in vkd3d.
Anyway, running
VKD3D_CONFIG=dxr VKD3D_TEST_FILTER=raytracing vkd3d-proton/build/tests/d3d12hangs, because a shader – probablyXRayClosest– is not bound correctly.When I add
XRayClosestto thedxil_exports, some tests still fail, but at least it doesn’t hang:Without this change, only two
stages(RayMissandRayGen) are passed tovkCreateRayTracingPipelinesKHR, but the groupinfo refers to shader stage 0, 1 and 2, 2 for the closest hit shader.Running with Vulkan validation layers (
VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation) prints a note:What I think is happening:
XRayClosestis exported in an extra rt object library that is added in a collection where exports isnull, which in dxr means everything will be exported. But translating this to the vulkan api misses adding these implicit exports to the stages, ending up with a reference to a non-existing stage.