iris: Only request an input mask if the shader needs it
authorJason Ekstrand <jason@jlekstrand.net>
Fri, 16 Aug 2019 22:48:53 +0000 (17:48 -0500)
committerJason Ekstrand <jason@jlekstrand.net>
Sat, 17 Aug 2019 00:59:42 +0000 (19:59 -0500)
Fixes: aebca3961b "iris: Fix handling of SIMD32 fragment shaders"
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/gallium/drivers/iris/iris_state.c

index bfc29d71496f001b62d7465501b06105d1338f12..3a31172c8960d75be2152b11a11b0ba639f6939b 100644 (file)
@@ -4778,7 +4778,9 @@ iris_upload_dirty_render_state(struct iris_context *ice,
             uint32_t psx_state[GENX(3DSTATE_PS_EXTRA_length)] = {0};
             iris_pack_command(GENX(3DSTATE_PS_EXTRA), psx_state, psx) {
 #if GEN_GEN >= 9
-               if (wm_prog_data->post_depth_coverage)
+               if (!wm_prog_data->uses_sample_mask)
+                  psx.InputCoverageMaskState  = ICMS_NONE;
+               else if (wm_prog_data->post_depth_coverage)
                   psx.InputCoverageMaskState = ICMS_DEPTH_COVERAGE;
                else if (wm_prog_data->inner_coverage &&
                         cso->conservative_rasterization)