panfrost: Drop panfrost_invalidate_frame
Only used to initialize active_queries once at context initialization, then unneeded. Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6327>
This commit is contained in:

committed by
Marge Bot

parent
1362371a96
commit
4b21c8b15f
@@ -144,16 +144,6 @@ panfrost_clear(
|
||||
panfrost_batch_clear(batch, buffers, color, depth, stencil);
|
||||
}
|
||||
|
||||
/* Reset per-frame context, called on context initialisation as well as after
|
||||
* flushing a frame */
|
||||
|
||||
void
|
||||
panfrost_invalidate_frame(struct panfrost_context *ctx)
|
||||
{
|
||||
/* TODO: When does this need to be handled? */
|
||||
ctx->active_queries = true;
|
||||
}
|
||||
|
||||
bool
|
||||
panfrost_writes_point_size(struct panfrost_context *ctx)
|
||||
{
|
||||
@@ -1041,7 +1031,6 @@ panfrost_set_framebuffer_state(struct pipe_context *pctx,
|
||||
|
||||
util_copy_framebuffer_state(&ctx->pipe_framebuffer, fb);
|
||||
ctx->batch = NULL;
|
||||
panfrost_invalidate_frame(ctx);
|
||||
|
||||
/* We may need to generate a new variant if the fragment shader is
|
||||
* keyed to the framebuffer format (due to EXT_framebuffer_fetch) */
|
||||
@@ -1491,7 +1480,6 @@ panfrost_create_context(struct pipe_screen *screen, void *priv, unsigned flags)
|
||||
/* Prepare for render! */
|
||||
|
||||
panfrost_batch_init(ctx);
|
||||
panfrost_invalidate_frame(ctx);
|
||||
|
||||
if (!(dev->quirks & IS_BIFROST)) {
|
||||
for (unsigned c = 0; c < PIPE_MAX_COLOR_BUFS; ++c)
|
||||
@@ -1500,6 +1488,7 @@ panfrost_create_context(struct pipe_screen *screen, void *priv, unsigned flags)
|
||||
|
||||
/* By default mask everything on */
|
||||
ctx->sample_mask = ~0;
|
||||
ctx->active_queries = true;
|
||||
|
||||
return gallium;
|
||||
}
|
||||
|
@@ -303,9 +303,6 @@ panfrost_get_shader_state(struct panfrost_context *ctx,
|
||||
struct pipe_context *
|
||||
panfrost_create_context(struct pipe_screen *screen, void *priv, unsigned flags);
|
||||
|
||||
void
|
||||
panfrost_invalidate_frame(struct panfrost_context *ctx);
|
||||
|
||||
bool
|
||||
panfrost_writes_point_size(struct panfrost_context *ctx);
|
||||
|
||||
|
@@ -121,22 +121,15 @@ panfrost_freeze_batch(struct panfrost_batch *batch)
|
||||
struct hash_entry *entry;
|
||||
|
||||
/* Remove the entry in the FBO -> batch hash table if the batch
|
||||
* matches. This way, next draws/clears targeting this FBO will trigger
|
||||
* the creation of a new batch.
|
||||
* matches and drop the context reference. This way, next draws/clears
|
||||
* targeting this FBO will trigger the creation of a new batch.
|
||||
*/
|
||||
entry = _mesa_hash_table_search(ctx->batches, &batch->key);
|
||||
if (entry && entry->data == batch)
|
||||
_mesa_hash_table_remove(ctx->batches, entry);
|
||||
|
||||
/* If this is the bound batch, the panfrost_context parameters are
|
||||
* relevant so submitting it invalidates those parameters, but if it's
|
||||
* not bound, the context parameters are for some other batch so we
|
||||
* can't invalidate them.
|
||||
*/
|
||||
if (ctx->batch == batch) {
|
||||
panfrost_invalidate_frame(ctx);
|
||||
if (ctx->batch == batch)
|
||||
ctx->batch = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef PAN_BATCH_DEBUG
|
||||
|
Reference in New Issue
Block a user