Mesa (staging/20.3): freedreno/a6xx: Fix assert which checks the count of shader outputs

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Dec 21 22:11:42 UTC 2020


Module: Mesa
Branch: staging/20.3
Commit: 633f60ee5738e4a89b838c9f52ef013204ac87de
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=633f60ee5738e4a89b838c9f52ef013204ac87de

Author: Danylo Piliaiev <dpiliaiev at igalia.com>
Date:   Mon Dec  7 15:56:03 2020 +0200

freedreno/a6xx: Fix assert which checks the count of shader outputs

The actual max count is 32 which corresponds to 128 output components.

Fixes: 2251a434 "freedreno/a6xx: Write multiple regs for SP_VS_OUT_REG and SP_VS_VPC_DST_REG"

Signed-off-by: Danylo Piliaiev <dpiliaiev at igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7917>
(cherry picked from commit 4b208fa36b484d2dbe0e7f1fc707544d3a1f17c5)

---

 .pick_status.json                                | 2 +-
 src/gallium/drivers/freedreno/a6xx/fd6_program.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/.pick_status.json b/.pick_status.json
index 8d350d9fd78..2c71ab14a72 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -157,7 +157,7 @@
         "description": "freedreno/a6xx: Fix assert which checks the count of shader outputs",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "master_sha": null,
         "because_sha": "2251a4345b1d9ebbf1defe533e16a2633d5127ef"
     },
diff --git a/src/gallium/drivers/freedreno/a6xx/fd6_program.c b/src/gallium/drivers/freedreno/a6xx/fd6_program.c
index 64690c99c1b..67fac488ad8 100644
--- a/src/gallium/drivers/freedreno/a6xx/fd6_program.c
+++ b/src/gallium/drivers/freedreno/a6xx/fd6_program.c
@@ -545,7 +545,7 @@ setup_stateobj(struct fd_ringbuffer *ring, struct fd_screen *screen,
 		setup_stream_out(state, last_shader, &l);
 	}
 
-	debug_assert(l.cnt < 32);
+	debug_assert(l.cnt <= 32);
 	if (gs)
 		OUT_PKT4(ring, REG_A6XX_SP_GS_OUT_REG(0), DIV_ROUND_UP(l.cnt, 2));
 	else if (ds)



More information about the mesa-commit mailing list