Mesa (staging/19.3): anv: Set up SBE_SWIZ properly for gl_Viewport

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Dec 3 18:40:48 UTC 2019


Module: Mesa
Branch: staging/19.3
Commit: 6bc243521a06b50b893bdcf9ea2fc2da303937c3
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=6bc243521a06b50b893bdcf9ea2fc2da303937c3

Author: Jason Ekstrand <jason at jlekstrand.net>
Date:   Tue Nov 26 15:08:43 2019 -0600

anv: Set up SBE_SWIZ properly for gl_Viewport

gl_Viewport is also in the VUE header so we need to whack the read
offset to 0 and emit a default (no overrides) SBE_SWIZ entry in that
case as well.

Cc: mesa-stable at lists.freedesktop.org
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
(cherry picked from commit b1f37688ba717db81a7e9c97e2a875d528d85112)

---

 src/intel/vulkan/genX_pipeline.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/intel/vulkan/genX_pipeline.c b/src/intel/vulkan/genX_pipeline.c
index 324a75feb44..85cd4e3e041 100644
--- a/src/intel/vulkan/genX_pipeline.c
+++ b/src/intel/vulkan/genX_pipeline.c
@@ -369,8 +369,8 @@ emit_3dstate_sbe(struct anv_pipeline *pipeline)
       if (input_index < 0)
          continue;
 
-      /* gl_Layer is stored in the VUE header */
-      if (attr == VARYING_SLOT_LAYER) {
+      /* gl_Viewport and gl_Layer are stored in the VUE header */
+      if (attr == VARYING_SLOT_VIEWPORT || attr == VARYING_SLOT_LAYER) {
          urb_entry_read_offset = 0;
          continue;
       }




More information about the mesa-commit mailing list