Hello, I’ve noticed there is support for running Nanite HW and SW rasterization in parallel using Async Compute, but it doesn’t work because overlapping UAV access from multiple queues is force disabled in D3D12RHI (see D3D12RHI.cpp:87).
I tested it a little bit by allowing overlapping and it seems to work without any artifacts or crashing. Verified in Nvidia Nsight that it actually runs in parallel on different queues.
- Do you know if it’s safe to allow multi queue UAV overlapping in DX12 in 5.5?
- If not, is it disabled because of API limitations or limitations in RDG synchronization?
- Do you have plans to enable it by default in the future?
Hi, thanks for reaching out about this. When you say you tested this by allowing overlapping, did you make any code changes to the engine to do this, or was this through changing cvars (r.Nanite.AsyncRasterization)? I will check with some folks about this and get back to you if enabling async rasterization for Nanite is safe. If such a feature is not enabled by default, there tends to be a good reason for it.
Hi Sergei,
I learned today that we do not allow UAV overlapping for multiple queues because this is technically not supported by D3D12 as an API. Although it looks like it works on your setup, depending on the driver and GPU your users might have, this is not guaranteed to be valid usage, which can lead to stability issues. Therefore, we will likely not enable this feature on D3D12 on PC platforms, and I would advise you to do the same. I hope that clarifies your questions, but please feel free to reach out if anything is unclear.
I had to remove the line mentioned in D3D12RHI.cpp, otherwise these CVars don’t do anything.