i965: Order write of query availablity with earlier writes
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 6 Oct 2016 20:07:18 +0000 (21:07 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Sat, 3 Jun 2017 12:38:45 +0000 (13:38 +0100)
commit8d07cb125c6afc11b6b8c7a97ec848868814b1d6
tree69ceef558c8bec9d95f1cecdbd30b286688bca8a
parent98fc0243ef7b0ce1e11061738756b0827c0d3c42
i965: Order write of query availablity with earlier writes

Currently we signal the availabilty of the query result using an
unordered pipe-control write. As it is unordered, it may be executed
before the write of the query result itself - and so an observer may
read the query result too early. Fix this by requesting that the write
of the availablity flag is ordered after earlier pipe control writes.

Testcase: piglit/arb_query_buffer_object-qbo/*async*
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Alejandro PiƱeiro <apinheiro@igalia.com>
src/mesa/drivers/dri/i965/gen6_queryobj.c