Mesa (staging/20.2): etnaviv: call nir_lower_bool_to_bitsize

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Aug 7 17:46:07 UTC 2020


Module: Mesa
Branch: staging/20.2
Commit: 1ed360d24b7c218226ec5d3582aec622d9d1a38a
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=1ed360d24b7c218226ec5d3582aec622d9d1a38a

Author: Christian Gmeiner <christian.gmeiner at gmail.com>
Date:   Tue Aug  4 22:44:21 2020 +0200

etnaviv: call nir_lower_bool_to_bitsize

Starting with commit 6f394343b1f ("nir/algebraic: i2f(f2i()) -> trunc()")
dEQP-GLES2.functional.shaders.operator.binary_operator.div.lowp_int_vertex
ends with an unsuppored flt instruction. Use nir_lower_bool_to_bitsize to
convert this flt to a flt32 which is supported. This fixes the introduced
regression.

Cc: 20.2 <mesa-stable at lists.freedesktop.org>
Signed-off-by: Christian Gmeiner <christian.gmeiner at gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6182>
(cherry picked from commit e63a7882a0ae2461cc2b84de96549c2df9d25985)

---

 .pick_status.json                                  | 2 +-
 src/gallium/drivers/etnaviv/etnaviv_compiler_nir.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.pick_status.json b/.pick_status.json
index a8bed381324..dd80650b78c 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -220,7 +220,7 @@
         "description": "etnaviv: call nir_lower_bool_to_bitsize",
         "nominated": true,
         "nomination_type": 0,
-        "resolution": 0,
+        "resolution": 1,
         "master_sha": null,
         "because_sha": null
     },
diff --git a/src/gallium/drivers/etnaviv/etnaviv_compiler_nir.c b/src/gallium/drivers/etnaviv/etnaviv_compiler_nir.c
index 3352510ac05..79ef97cdbde 100644
--- a/src/gallium/drivers/etnaviv/etnaviv_compiler_nir.c
+++ b/src/gallium/drivers/etnaviv/etnaviv_compiler_nir.c
@@ -1138,6 +1138,7 @@ etna_compile_shader_nir(struct etna_shader_variant *v)
 
    NIR_PASS_V(s, nir_opt_dce);
 
+   NIR_PASS_V(s, nir_lower_bool_to_bitsize);
    NIR_PASS_V(s, etna_lower_alu, c->specs->has_new_transcendentals);
 
    if (DBG_ENABLED(ETNA_DBG_DUMP_SHADERS))



More information about the mesa-commit mailing list