From c1307184d21ade30cdeaa075b842060130c79e7c Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Wed, 6 Mar 2024 10:32:43 +0100 Subject: [PATCH] radv: stop using the custom blend mode for PS epilogs Internal operations that set the custom blend mode are monolithic pipelines only, and the value should always be zero. Signed-off-by: Samuel Pitoiset Part-of: --- src/amd/vulkan/radv_cmd_buffer.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c index e7386be1800..d185ccabd5a 100644 --- a/src/amd/vulkan/radv_cmd_buffer.c +++ b/src/amd/vulkan/radv_cmd_buffer.c @@ -1879,8 +1879,7 @@ radv_emit_ps_epilog_state(struct radv_cmd_buffer *cmd_buffer, struct radv_shader uint32_t col_format = radv_compact_spi_shader_col_format(ps_shader, ps_epilog->spi_shader_col_format); - bool need_null_export_workaround = - radv_needs_null_export_workaround(device, ps_shader, cmd_buffer->state.custom_blend_mode); + bool need_null_export_workaround = radv_needs_null_export_workaround(device, ps_shader, 0); if (need_null_export_workaround && !col_format) col_format = V_028714_SPI_SHADER_32_R; radeon_set_context_reg(cmd_buffer->cs, R_028714_SPI_SHADER_COL_FORMAT, col_format); @@ -9223,8 +9222,10 @@ radv_emit_all_graphics_states(struct radv_cmd_buffer *cmd_buffer, const struct r cmd_buffer->state.col_format_non_compacted = ps_epilog->spi_shader_col_format; - bool need_null_export_workaround = radv_needs_null_export_workaround( - device, cmd_buffer->state.shaders[MESA_SHADER_FRAGMENT], cmd_buffer->state.custom_blend_mode); + assert(cmd_buffer->state.custom_blend_mode == 0); + + bool need_null_export_workaround = + radv_needs_null_export_workaround(device, cmd_buffer->state.shaders[MESA_SHADER_FRAGMENT], 0); if (need_null_export_workaround && !cmd_buffer->state.col_format_non_compacted) cmd_buffer->state.col_format_non_compacted = V_028714_SPI_SHADER_32_R;