iris: Replace unconditional QBO flush with iris_dirty_for_history().

We can now use the same cache tracking mechanism for synchronizing QBO
writes instead of the unconditional PIPE_CONTROL performed currently,
which is unable to invalidate any incoherent caches which may contain
stale data for the buffer object.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15738>
This commit is contained in:
Francisco Jerez 2020-02-06 20:58:40 -08:00 committed by Kenneth Graunke
parent 6cc09699cd
commit 03cf788891

View file

@ -699,13 +699,8 @@ iris_get_query_result_resource(struct pipe_context *ctx,
batch->screen->vtbl.store_data_imm64(batch, dst_bo, offset, q->result);
}
/* Make sure the result lands before they use bind the QBO elsewhere
* and use the result.
*/
// XXX: Why? i965 doesn't do this.
iris_emit_pipe_control_flush(batch,
"query: unknown QBO flushing hack",
PIPE_CONTROL_CS_STALL);
/* Make sure QBO is flushed before its result is used elsewhere. */
iris_dirty_for_history(ice, res);
return;
}