Mesa (staging/20.0): llvmpipe: Fix real uninitialized use of "atype" for SEMANTIC_FACE

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Feb 20 21:35:52 UTC 2020


Module: Mesa
Branch: staging/20.0
Commit: d499e9b4e25daf4649cce11354249a2a68d5571d
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=d499e9b4e25daf4649cce11354249a2a68d5571d

Author: Eric Anholt <eric at anholt.net>
Date:   Tue Jan 28 13:14:47 2020 -0800

llvmpipe: Fix real uninitialized use of "atype" for SEMANTIC_FACE

Fixes: 502548a09c5a ("gallivm/llvmpipe: add support for front facing in sysval.")
Reviewed-by: Roland Scheidegger <sroland at vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3867>
(cherry picked from commit 45b2ccc6b30c9e4c3382e6b462a2f5357c15d3b8)

---

 .pick_status.json                               | 2 +-
 src/gallium/auxiliary/gallivm/lp_bld_tgsi_soa.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.pick_status.json b/.pick_status.json
index 1cd9ef028be..94d53f2384d 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -391,7 +391,7 @@
         "description": "llvmpipe: Fix real uninitialized use of \"atype\" for SEMANTIC_FACE",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "master_sha": null,
         "because_sha": "502548a09c5a87d06da97be45a2386bb1e5e800e"
     },
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_tgsi_soa.c b/src/gallium/auxiliary/gallivm/lp_bld_tgsi_soa.c
index b1a2e96e804..adcf1871f8a 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_tgsi_soa.c
+++ b/src/gallium/auxiliary/gallivm/lp_bld_tgsi_soa.c
@@ -1548,6 +1548,7 @@ emit_fetch_system_value(
 
    case TGSI_SEMANTIC_FACE:
       res = lp_build_broadcast_scalar(&bld_base->uint_bld, bld->system_values.front_facing);
+      atype = TGSI_TYPE_UNSIGNED;
       break;
 
   case TGSI_SEMANTIC_DRAWID:



More information about the mesa-commit mailing list