kopper: apply ancillary invalidation through glthread on swapbuffers

this fixes invalidations with tc's renderpass parsing so they get picked
up before the renderpass ends

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21910>
This commit is contained in:
Mike Blumenkrantz
2023-03-14 16:54:07 -04:00
committed by Marge Bot
parent bd74da9d2a
commit dd8d52cabc

View File

@@ -853,6 +853,10 @@ kopperSwapBuffers(__DRIdrawable *dPriv, uint32_t flush_flags)
if (!ptex)
return 0;
/* ensure invalidation is applied before renderpass ends */
if (flush_flags & __DRI2_FLUSH_INVALIDATE_ANCILLARY)
_mesa_glthread_invalidate_zsbuf(ctx->st->ctx);
/* Wait for glthread to finish because we can't use pipe_context from
* multiple threads.
*/