mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-06 15:20:17 +01:00
etnaviv: fix texture barrier implementation
The current implementation has a number of issues: - it doesn't flush the depth cache, even though this can also be changed due to fragment shader operations and thus is included in the definition of glTextureBarrier - it doesn't flush the vertex sampler cache - it doesn't stall the pipeline until the flushes are done Fix those issues and drop the comment, as it's pretty clear from the code what is being done. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22104>
This commit is contained in:
parent
77ab87e5a7
commit
9df5a2bd62
1 changed files with 7 additions and 3 deletions
|
|
@ -337,9 +337,13 @@ static void
|
|||
etna_texture_barrier(struct pipe_context *pctx, unsigned flags)
|
||||
{
|
||||
struct etna_context *ctx = etna_context(pctx);
|
||||
/* clear color and texture cache to make sure that texture unit reads
|
||||
* what has been written */
|
||||
etna_set_state(ctx->stream, VIVS_GL_FLUSH_CACHE, VIVS_GL_FLUSH_CACHE_COLOR | VIVS_GL_FLUSH_CACHE_TEXTURE);
|
||||
|
||||
etna_set_state(ctx->stream, VIVS_GL_FLUSH_CACHE,
|
||||
VIVS_GL_FLUSH_CACHE_COLOR | VIVS_GL_FLUSH_CACHE_DEPTH |
|
||||
VIVS_GL_FLUSH_CACHE_TEXTURE);
|
||||
etna_set_state(ctx->stream, VIVS_GL_FLUSH_CACHE,
|
||||
VIVS_GL_FLUSH_CACHE_TEXTUREVS);
|
||||
etna_stall(ctx->stream, SYNC_RECIPIENT_RA, SYNC_RECIPIENT_PE);
|
||||
}
|
||||
|
||||
uint32_t
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue