zink: add a flag to indicate whether a descriptor buffer is bound

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21085>
This commit is contained in:
Mike Blumenkrantz 2023-02-02 17:09:14 -05:00 committed by Marge Bot
parent f81a4e904c
commit 6b49dec675
2 changed files with 3 additions and 0 deletions

View file

@ -155,6 +155,7 @@ zink_reset_batch_state(struct zink_context *ctx, struct zink_batch_state *bs)
*/
bs->fence.submitted = false;
bs->has_barriers = false;
bs->db_bound = false;
if (bs->fence.batch_id)
zink_screen_update_last_finished(screen, bs->fence.batch_id);
bs->submit_count++;
@ -421,6 +422,7 @@ zink_batch_bind_db(struct zink_context *ctx)
assert(infos[i].usage);
}
VKSCR(CmdBindDescriptorBuffersEXT)(batch->state->cmdbuf, count, infos);
batch->state->db_bound = true;
}
/* called on context creation and after flushing an old batch */

View file

@ -580,6 +580,7 @@ struct zink_batch_state {
bool is_device_lost;
bool has_barriers;
bool db_bound;
};
static inline struct zink_batch_state *