From: Jason Ekstrand Date: Wed, 30 Oct 2019 20:50:51 +0000 (-0500) Subject: anv: Don't delete fragment shaders that write sample mask X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=df7a730b4f694f6a07e7d6fd673453b8315ae867;p=mesa.git anv: Don't delete fragment shaders that write sample mask Also, use color_outputs_valid rather than nr_color_outputs since it should be a bit more accurate. Reviewed-by: Rafael Antognolli --- diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c index 68a8ca0c026..1a2eb4599c8 100644 --- a/src/intel/vulkan/anv_pipeline.c +++ b/src/intel/vulkan/anv_pipeline.c @@ -1056,8 +1056,10 @@ anv_pipeline_compile_fs(const struct brw_compiler *compiler, (uint32_t)fs_stage->prog_data.wm.dispatch_16 + (uint32_t)fs_stage->prog_data.wm.dispatch_32; - if (fs_stage->key.wm.nr_color_regions == 0 && + if (fs_stage->key.wm.color_outputs_valid == 0 && !fs_stage->prog_data.wm.has_side_effects && + !fs_stage->prog_data.wm.uses_omask && + !fs_stage->key.wm.alpha_to_coverage && !fs_stage->prog_data.wm.uses_kill && fs_stage->prog_data.wm.computed_depth_mode == BRW_PSCDEPTH_OFF && !fs_stage->prog_data.wm.computed_stencil) {