aboutsummaryrefslogtreecommitdiffstats
path: root/scons
diff options
context:
space:
mode:
authorLionel Landwerlin <[email protected]>2019-05-01 12:30:41 +0100
committerLionel Landwerlin <[email protected]>2019-05-08 09:49:09 +0000
commita07d06f10352fc5fa40db8a723fa5842ebc660db (patch)
tree6d8b51549eb496edd7a8f0d1729f387850eb4f20 /scons
parente19a8fe033fd4c60b00b6824c83697df712a9e95 (diff)
anv: rework queries writes to ensure ordering memory writes
We use a mix of MI & PIPE_CONTROL commands to write our queries' data (results & availability). Those commands' memory write order is not guaranteed with regard to their order in the command stream, unless CS stalls are inserted between them. This is problematic for 2 reasons : 1. We copy results from the device using MI commands even though the values are generated from PIPE_CONTROL, meaning we could copy unlanded values into the results and then copy the availability that is inconsistent with the values. 2. We allow the user to poll on the availability values of the query pool from the CPU. If the availability lands in memory before the values then we could return invalid values. This change does 2 things to address this problem : - We use either PIPE_CONTROL or MI commands to write both queries values and availability, so that the ordering of the memory writes guarantees that if availability is visible, results are also visible. - For the occlusion & timestamp queries we apply a CS stall before copying the results on the device, to ensure copying with MI commands see the correct values of previous PIPE_CONTROL writes of availability (required by the Vulkan spec). Signed-off-by: Lionel Landwerlin <[email protected]> Reported-by: Iago Toral Quiroga <[email protected]> Cc: [email protected] Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'scons')
0 files changed, 0 insertions, 0 deletions