-
Notifications
You must be signed in to change notification settings - Fork 463
Description
Describe the situation in which you encountered the missing validation
VK_LAYER_KHRONOS_validation + validate_sync + gpuav_enable + exclusive queue ownership resources
I have a setup in which i'm expecting a WAW error, but i'm not getting it. Now that could be good, but i'm not entirely convinced that my code is actually valid. Here's the steps i'm executing:
On the Transfer QF:
- vkCmdCopyBuffer
- Release barrier ALL_TRANSFER / MEMORY_WRITE -> ALL_COMMANDS / MEMORY_READ
- Signal semaphore
On the Compute QF:
- Wait semaphore
- Acquire barrier ALL_TRANSFER / MEMORY_WRITE -> ALL_COMMANDS / MEMORY_READ
- Signal fence
On Host:
- WaitForFences
On the Compute QF:
- vkCmdBindDescriptorSets (containing that buffer)
- vkCmdDispatch (writing to the buffer)
What i'm worried about is that the QFOT barrier doesn't properly prevent compute memory writes from happening before the resource has been acquired on the Compute QF or the initial data has been copied.
Valid Usage IDs requested
To be honest i have not done the full evidence gathering yet. If you agree this looks suspicious, I'd be willing to do some digging to see if something is listed in the specs about this.
Additional Context
I have a renderdoc capture of a simplified app doing almost the same thing. The difference with the more involved app is that this capture doesn't use writeonly on the output buffer. One could then argue that since the shader is also reading and writing is dependent on reads that it's still valid. Using this example for simplicity of illustration though, the other app also doesn't give the validation error.
https://drive.google.com/file/d/1OnXxckJuXMOtuIClSnfV9g6g7bgCIj_9/view?usp=sharing
EID 107: vkCmdCopyBuffer (to buffer 569)
EID 108: release barrier
EID 112: acquire barrier
EID 114: vkWaitForFences
EID 128: vkUpdateDescriptorSets (buffer 569)
EID 134: vkCmdBindDescriptorSets
EID 136: vkCmdDispatch