diff options
author | Jason Ekstrand <[email protected]> | 2016-03-08 16:54:07 -0800 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2016-03-08 16:54:07 -0800 |
commit | 28cbc45b3c83d645bb2b805a0ed6008e2f9dad61 (patch) | |
tree | f271f2fc153c3260c0cd88431d0dad0e27cd31de /src/intel/vulkan/gen7_cmd_buffer.c | |
parent | 42b4c0fa6e0909e9622b03d56393ddec173ebe5d (diff) |
anv/cmd_buffer: Split flush_state into two functions
Diffstat (limited to 'src/intel/vulkan/gen7_cmd_buffer.c')
-rw-r--r-- | src/intel/vulkan/gen7_cmd_buffer.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/intel/vulkan/gen7_cmd_buffer.c b/src/intel/vulkan/gen7_cmd_buffer.c index 8dce586eec7..d552f1b4b8a 100644 --- a/src/intel/vulkan/gen7_cmd_buffer.c +++ b/src/intel/vulkan/gen7_cmd_buffer.c @@ -462,6 +462,8 @@ genX(cmd_buffer_flush_state)(struct anv_cmd_buffer *cmd_buffer) } } + cmd_buffer->state.vb_dirty &= ~vb_emit; + if (cmd_buffer->state.dirty & ANV_CMD_DIRTY_PIPELINE) { /* If somebody compiled a pipeline after starting a command buffer the * scratch bo may have grown since we started this cmd buffer (and @@ -521,6 +523,14 @@ genX(cmd_buffer_flush_state)(struct anv_cmd_buffer *cmd_buffer) if (cmd_buffer->state.dirty & ANV_CMD_DIRTY_DYNAMIC_SCISSOR) gen7_cmd_buffer_emit_scissor(cmd_buffer); + genX(cmd_buffer_flush_dynamic_state)(cmd_buffer); +} + +void +genX(cmd_buffer_flush_dynamic_state)(struct anv_cmd_buffer *cmd_buffer) +{ + struct anv_pipeline *pipeline = cmd_buffer->state.pipeline; + if (cmd_buffer->state.dirty & (ANV_CMD_DIRTY_PIPELINE | ANV_CMD_DIRTY_RENDER_TARGETS | ANV_CMD_DIRTY_DYNAMIC_LINE_WIDTH | @@ -622,7 +632,6 @@ genX(cmd_buffer_flush_state)(struct anv_cmd_buffer *cmd_buffer) .BufferEndingAddress = { buffer->bo, buffer->offset + buffer->size }); } - cmd_buffer->state.vb_dirty &= ~vb_emit; cmd_buffer->state.dirty = 0; } |