summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/radeonsi/si_state.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/radeonsi/si_state.c')
-rw-r--r--src/gallium/drivers/radeonsi/si_state.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c
index f5c23830e39..2e2be235cf7 100644
--- a/src/gallium/drivers/radeonsi/si_state.c
+++ b/src/gallium/drivers/radeonsi/si_state.c
@@ -4784,6 +4784,7 @@ static void si_bind_vertex_elements(struct pipe_context *ctx, void *state)
if (sctx->num_vertex_elements) {
sctx->vertex_buffers_dirty = true;
} else {
+ sctx->vertex_buffers_dirty = false;
sctx->vertex_buffer_pointer_dirty = false;
sctx->vertex_buffer_user_sgprs_dirty = false;
}
@@ -4862,7 +4863,8 @@ static void si_set_vertex_buffers(struct pipe_context *ctx, unsigned start_slot,
for (i = 0; i < count; i++)
pipe_resource_reference(&dst[i].buffer.resource, NULL);
}
- sctx->vertex_buffers_dirty = true;
+
+ sctx->vertex_buffers_dirty = sctx->num_vertex_elements > 0;
sctx->vertex_buffer_unaligned = (orig_unaligned & ~updated_mask) | unaligned;
/* Check whether alignment may have changed in a way that requires