Module: Mesa Branch: main Commit: 8c4e33cdabf44596461c6a216294e5785058fc9c URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=8c4e33cdabf44596461c6a216294e5785058fc9c
Author: Samuel Pitoiset <[email protected]> Date: Tue Jul 19 13:42:00 2022 +0200 radv: do not try to remove color exports for FS that need an epilog The color format would be zero and all exports would be removed. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Reviewed-by: Timur Kristóf <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18255> --- src/amd/vulkan/radv_pipeline.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/amd/vulkan/radv_pipeline.c b/src/amd/vulkan/radv_pipeline.c index 1b84961761f..a0c32f5a285 100644 --- a/src/amd/vulkan/radv_pipeline.c +++ b/src/amd/vulkan/radv_pipeline.c @@ -2572,7 +2572,10 @@ radv_pipeline_link_fs(struct radv_pipeline_stage *fs_stage, { assert(fs_stage->nir->info.stage == MESA_SHADER_FRAGMENT); - radv_remove_color_exports(pipeline_key, fs_stage->nir); + if (!pipeline_key->ps.has_epilog) { + /* Only remove color exports when the format is known. */ + radv_remove_color_exports(pipeline_key, fs_stage->nir); + } nir_foreach_shader_out_variable(var, fs_stage->nir) { var->data.driver_location = var->data.location + var->data.index;
