Mesa (main): pan/bi: Handle Valhall texturing in helper analysis

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Apr 7 14:34:59 UTC 2022


Module: Mesa
Branch: main
Commit: 9758555481170be6a77709dfb90206e834724c24
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=9758555481170be6a77709dfb90206e834724c24

Author: Alyssa Rosenzweig <alyssa at collabora.com>
Date:   Tue Aug  3 11:11:42 2021 -0400

pan/bi: Handle Valhall texturing in helper analysis

Signed-off-by: Alyssa Rosenzweig <alyssa at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15793>

---

 src/panfrost/bifrost/bi_helper_invocations.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/panfrost/bifrost/bi_helper_invocations.c b/src/panfrost/bifrost/bi_helper_invocations.c
index 975d43fd847..b69944a03d5 100644
--- a/src/panfrost/bifrost/bi_helper_invocations.c
+++ b/src/panfrost/bifrost/bi_helper_invocations.c
@@ -65,6 +65,7 @@ static bool
 bi_has_skip_bit(enum bi_opcode op)
 {
         switch (op) {
+        case BI_OPCODE_TEX_SINGLE:
         case BI_OPCODE_TEXC:
         case BI_OPCODE_TEXS_2D_F16:
         case BI_OPCODE_TEXS_2D_F32:
@@ -94,6 +95,9 @@ bi_instr_uses_helpers(bi_instr *I)
         case BI_OPCODE_VAR_TEX_F16:
         case BI_OPCODE_VAR_TEX_F32:
                 return !I->lod_mode; /* set for zero, clear for computed */
+        case BI_OPCODE_TEX_SINGLE:
+                return (I->va_lod_mode == BI_VA_LOD_MODE_COMPUTED_LOD) ||
+                       (I->va_lod_mode == BI_VA_LOD_MODE_COMPUTED_BIAS);
         case BI_OPCODE_CLPER_I32:
         case BI_OPCODE_CLPER_V6_I32:
                 /* Fragment shaders require helpers to implement derivatives.



More information about the mesa-commit mailing list