Mesa (staging/22.0): Revert "zink: always set VkPipelineMultisampleStateCreateInfo::pSampleMask"

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Feb 24 17:06:47 UTC 2022


Module: Mesa
Branch: staging/22.0
Commit: 669543ee355793d02c9959e72c6abd4c9fe7ee21
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=669543ee355793d02c9959e72c6abd4c9fe7ee21

Author: Dylan Baker <dylan.c.baker at intel.com>
Date:   Thu Feb 24 09:06:37 2022 -0800

Revert "zink: always set VkPipelineMultisampleStateCreateInfo::pSampleMask"

This reverts commit 42e4600e87c446b757709d5bcdf0782da9c6d245.

---

 .pick_status.json                        | 2 +-
 src/gallium/drivers/zink/zink_context.c  | 1 -
 src/gallium/drivers/zink/zink_pipeline.c | 8 +-------
 3 files changed, 2 insertions(+), 9 deletions(-)

diff --git a/.pick_status.json b/.pick_status.json
index cb4e76f5ea3..b95e0ea8099 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -3613,7 +3613,7 @@
         "description": "zink: always set VkPipelineMultisampleStateCreateInfo::pSampleMask",
         "nominated": true,
         "nomination_type": 0,
-        "resolution": 1,
+        "resolution": 0,
         "main_sha": null,
         "because_sha": null
     },
diff --git a/src/gallium/drivers/zink/zink_context.c b/src/gallium/drivers/zink/zink_context.c
index 8ba6fcbdea4..56ca890c395 100644
--- a/src/gallium/drivers/zink/zink_context.c
+++ b/src/gallium/drivers/zink/zink_context.c
@@ -4092,7 +4092,6 @@ zink_context_create(struct pipe_screen *pscreen, void *priv, unsigned flags)
    ctx->base.set_patch_vertices = zink_set_patch_vertices;
 
    ctx->base.set_sample_mask = zink_set_sample_mask;
-   ctx->gfx_pipeline_state.sample_mask = UINT32_MAX;
 
    ctx->base.clear = zink_clear;
    ctx->base.clear_texture = zink_clear_texture;
diff --git a/src/gallium/drivers/zink/zink_pipeline.c b/src/gallium/drivers/zink/zink_pipeline.c
index 0fceb9ebaaa..b4f5d3a4383 100644
--- a/src/gallium/drivers/zink/zink_pipeline.c
+++ b/src/gallium/drivers/zink/zink_pipeline.c
@@ -132,13 +132,7 @@ zink_create_gfx_pipeline(struct zink_screen *screen,
          warn_missing_feature("alphaToOne");
       ms_state.alphaToOneEnable = state->blend_state->alpha_to_one;
    }
-   /* "If pSampleMask is NULL, it is treated as if the mask has all bits set to 1."
-    * - Chapter 27. Rasterization
-    * 
-    * thus it never makes sense to leave this as NULL since gallium will provide correct
-    * data here as long as sample_mask is initialized on context creation
-    */
-   ms_state.pSampleMask = &state->sample_mask;
+   ms_state.pSampleMask = state->sample_mask ? &state->sample_mask : NULL;
    if (hw_rast_state->force_persample_interp) {
       ms_state.sampleShadingEnable = VK_TRUE;
       ms_state.minSampleShading = 1.0;



More information about the mesa-commit mailing list