pan/va: Add VAR_TEX_BUF_GRADIENT instruction
authorAlyssa Rosenzweig <alyssa@collabora.com>
Mon, 2 May 2022 14:58:43 +0000 (10:58 -0400)
committerAlyssa Rosenzweig <alyssa@collabora.com>
Mon, 2 May 2022 15:11:25 +0000 (11:11 -0400)
Probably useful for ... something.

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

src/panfrost/bifrost/valhall/ISA.xml
src/panfrost/bifrost/valhall/valhall.c.py
src/panfrost/bifrost/valhall/valhall.py

index f41fcf8..3c160b1 100644 (file)
     <src>Varying offset</src>
   </ins>
 
+  <ins name="VAR_TEX_BUF_GRADIENT" title="Fused varying-texturing" opcode="0x132" unit="VT">
+    <desc>
+      Only works for FP32 varyings. Performance characteristics are similar
+      to LD_VAR_BUF_IMM_F32.v2.f32 followed by TEX, using both V and T units.
+    </desc>
+    <slot/>
+    <skip/>
+    <sample_and_update/>
+    <register_type/>
+    <vartex_register_width/>
+    <dimension/>
+    <array_enable/>
+    <shadow/>
+    <lod_bias_disable/>
+    <lod_clamp_disable/>
+
+    <sr_write_count/>
+
+    <sr write="true"/>
+    <src size="64">Image to read from</src>
+    <src>Varying offset</src>
+  </ins>
+
   <ins name="VAR_TEX_BUF_DUAL" title="Fused varying-texturing" opcode="0x137" unit="VT">
     <desc>
       Only works for FP32 varyings. Performance characteristics are similar
index 78e397e..55bfa2c 100644 (file)
@@ -68,6 +68,7 @@ SKIP = set([
         # VAR_TEX
         "VAR_TEX_BUF_SINGLE",
         "VAR_TEX_BUF_GATHER",
+        "VAR_TEX_BUF_GRADIENT",
         "VAR_TEX_BUF_DUAL",
 
         # Special cased
index e4b51c6..dd4c274 100644 (file)
@@ -380,6 +380,8 @@ MODIFIERS = {
     "integer_coordinates": Flag("integer_coordinates", 13),
     "fetch_component": Modifier("fetch_component", 14, 2),
     "lod_mode": Modifier("lod_mode", 13, 3),
+    "lod_bias_disable": Modifier("lod_mode", 13, 1),
+    "lod_clamp_disable": Modifier("lod_mode", 14, 1),
     "write_mask": Modifier("write_mask", 22, 4),
     "register_type": Modifier("register_type", 26, 2),
     "dimension": Modifier("dimension", 28, 2),