{
assert(stage < PIPE_SHADER_COMPUTE);
ctx->gfx_stages[stage] = shader;
- ctx->dirty |= ZINK_DIRTY_PROGRAM;
+ ctx->dirty_program = true;
}
static void
static struct zink_gfx_program *
get_gfx_program(struct zink_context *ctx)
{
- if (ctx->dirty & ZINK_DIRTY_PROGRAM) {
+ if (ctx->dirty_program) {
struct hash_entry *entry = _mesa_hash_table_search(ctx->program_cache,
ctx->gfx_stages);
if (!entry) {
return NULL;
}
ctx->curr_program = entry->data;
- ctx->dirty &= ~ZINK_DIRTY_PROGRAM;
+ ctx->dirty_program = false;
}
assert(ctx->curr_program);
!ctx->framebuffer_cache)
goto fail;
- ctx->dirty = ZINK_DIRTY_PROGRAM;
+ ctx->dirty_program = true;
/* start the first batch */
zink_start_batch(ctx, zink_curr_batch(ctx));
return (struct zink_sampler_view *)pview;
}
-#define ZINK_DIRTY_PROGRAM (1 << 0)
-
struct zink_context {
struct pipe_context base;
struct slab_child_pool transfer_pool;
struct zink_gfx_pipeline_state gfx_pipeline_state;
struct hash_table *program_cache;
struct zink_gfx_program *curr_program;
- unsigned dirty;
+
+ unsigned dirty_program : 1;
struct hash_table *render_pass_cache;
struct hash_table *framebuffer_cache;