void anv_cmd_buffer_set_subpass(struct anv_cmd_buffer *cmd_buffer,
struct anv_subpass *subpass);
+void gen7_flush_pipeline_select_3d(struct anv_cmd_buffer *cmd_buffer);
+void gen75_flush_pipeline_select_3d(struct anv_cmd_buffer *cmd_buffer);
+void gen8_flush_pipeline_select_3d(struct anv_cmd_buffer *cmd_buffer);
+void gen9_flush_pipeline_select_3d(struct anv_cmd_buffer *cmd_buffer);
+
void gen7_cmd_buffer_flush_state(struct anv_cmd_buffer *cmd_buffer);
void gen75_cmd_buffer_flush_state(struct anv_cmd_buffer *cmd_buffer);
void gen8_cmd_buffer_flush_state(struct anv_cmd_buffer *cmd_buffer);
assert((pipeline->active_stages & VK_SHADER_STAGE_COMPUTE_BIT) == 0);
- if (cmd_buffer->state.current_pipeline != _3D) {
- anv_batch_emit(&cmd_buffer->batch, GEN7_PIPELINE_SELECT,
- .PipelineSelection = _3D);
- cmd_buffer->state.current_pipeline = _3D;
- }
+ genX(flush_pipeline_select_3d)(cmd_buffer);
if (vb_emit) {
const uint32_t num_buffers = __builtin_popcount(vb_emit);
}
}
-static void
-flush_pipeline_select_3d(struct anv_cmd_buffer *cmd_buffer)
-{
- config_l3(cmd_buffer, false);
-
- if (cmd_buffer->state.current_pipeline != _3D) {
- anv_batch_emit(&cmd_buffer->batch, GENX(PIPELINE_SELECT),
-#if ANV_GEN >= 9
- .MaskBits = 3,
-#endif
- .PipelineSelection = _3D);
- cmd_buffer->state.current_pipeline = _3D;
- }
-}
-
static void
__emit_genx_sf_state(struct anv_cmd_buffer *cmd_buffer)
{
assert((pipeline->active_stages & VK_SHADER_STAGE_COMPUTE_BIT) == 0);
- flush_pipeline_select_3d(cmd_buffer);
+ config_l3(cmd_buffer, false);
+
+ genX(flush_pipeline_select_3d)(cmd_buffer);
if (vb_emit) {
const uint32_t num_buffers = __builtin_popcount(vb_emit);
cmd_buffer->state.pass = pass;
anv_cmd_state_setup_attachments(cmd_buffer, pRenderPassBegin);
- flush_pipeline_select_3d(cmd_buffer);
+ genX(flush_pipeline_select_3d)(cmd_buffer);
const VkRect2D *render_area = &pRenderPassBegin->renderArea;
anv_batch_emit(&cmd_buffer->batch, GENX(MEDIA_STATE_FLUSH));
}
+
+void
+genX(flush_pipeline_select_3d)(struct anv_cmd_buffer *cmd_buffer)
+{
+ if (cmd_buffer->state.current_pipeline != _3D) {
+ anv_batch_emit(&cmd_buffer->batch, GENX(PIPELINE_SELECT),
+#if ANV_GEN >= 9
+ .MaskBits = 3,
+#endif
+ .PipelineSelection = _3D);
+ cmd_buffer->state.current_pipeline = _3D;
+ }
+}