anv: Re-emit vertex buffers when the pipeline changes
authorJason Ekstrand <jason.ekstrand@intel.com>
Tue, 21 Aug 2018 22:14:38 +0000 (17:14 -0500)
committerJason Ekstrand <jason.ekstrand@intel.com>
Fri, 7 Sep 2018 20:19:02 +0000 (15:19 -0500)
Some of the bits of VERTEX_BUFFER_STATE such as access type, instance
data step rate, and pitch come from the pipeline.

Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/intel/vulkan/genX_cmd_buffer.c

index 1aeb32cab038d0d85f7aa72abb154643e9691a51..2928713ebe09e79ae225c097380f84b7e31c9b8d 100644 (file)
@@ -2491,6 +2491,8 @@ genX(cmd_buffer_flush_state)(struct anv_cmd_buffer *cmd_buffer)
    uint32_t *p;
 
    uint32_t vb_emit = cmd_buffer->state.gfx.vb_dirty & pipeline->vb_used;
+   if (cmd_buffer->state.gfx.dirty & ANV_CMD_DIRTY_PIPELINE)
+      vb_emit |= pipeline->vb_used;
 
    assert((pipeline->active_stages & VK_SHADER_STAGE_COMPUTE_BIT) == 0);