pan/va: Generalize message? check for asm
authorAlyssa Rosenzweig <alyssa@collabora.com>
Mon, 2 May 2022 15:10:37 +0000 (11:10 -0400)
committerAlyssa Rosenzweig <alyssa@collabora.com>
Mon, 2 May 2022 15:11:08 +0000 (11:11 -0400)
Allows passing more uniforms in more places. We'll use this in a test case in a
moment.

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

src/panfrost/bifrost/valhall/asm.py
src/panfrost/bifrost/valhall/valhall.py

index fbaedf8..6b7b5ce 100644 (file)
@@ -216,8 +216,7 @@ def parse_asm(line):
         # Set a placeholder writemask to prevent encoding faults
         encoded |= (0xC0 << 40)
 
-    # TODO: Other messages
-    fau = FAUState(message = ins.name.startswith('LD_BUFFER'))
+    fau = FAUState(message = ins.message)
 
     for i, (op, src) in enumerate(zip(operands, ins.srcs)):
         parts = op.split('.')
index 9ae7000..de20fbb 100644 (file)
@@ -192,6 +192,9 @@ class Instruction:
         self.staging = staging
         self.unit = unit
 
+        # Message-passing instruction <===> not ALU instruction
+        self.message = unit not in ["FMA", "CVT", "SFU"]
+
         self.secondary_shift = max(len(self.srcs) * 8, 16)
         self.secondary_mask = 0xF if opcode2 is not None else 0x0
         if "left" in [x.name for x in self.modifiers]: