panfrost/decode: Expand pointers in compute descriptor
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Wed, 19 Jun 2019 15:55:03 +0000 (08:55 -0700)
committerAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Thu, 20 Jun 2019 14:48:04 +0000 (07:48 -0700)
Just as an aid.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
src/gallium/drivers/panfrost/include/panfrost-job.h
src/gallium/drivers/panfrost/pandecode/decode.c

index 4b3c788e4e96d160ff1fbb430d468165330cc6ff..aaf6de72bc6e46d5b4d8cc656b6d5147804bad7b 100644 (file)
@@ -1410,7 +1410,16 @@ struct mali_single_framebuffer {
  * of compute jobs. Superficially resembles a single framebuffer descriptor */
 
 struct mali_compute_fbd {
-        u32 unknown[64];
+        u32 unknown1[16];
+        mali_ptr unknown2;
+        mali_ptr unknown3;
+        u32 unknown4[16];
+        u32 unknown5[18];
+        mali_ptr unknown6;
+        u32 unknown7[4];
+        mali_ptr unknown8;
+        mali_ptr unknown9;
+        u32 unknown10[16];
 } __attribute__((packed));
 
 /* Format bits for the render target flags */
index 61e0a0123e40505ad24a3b85706ff6520ebedf95..3757ee9dd4f0dbcac4bb088047a7407b264a75ed 100644 (file)
@@ -539,6 +539,20 @@ pandecode_replay_sfbd(uint64_t gpu_va, int job_no)
         printf("},\n");
 }
 
+static void
+pandecode_u32_slide(unsigned name, const u32 *slide, unsigned count)
+{
+        pandecode_log(".unknown%d = {", name);
+
+        for (int i = 0; i < count; ++i)
+                printf("%X, ", slide[i]);
+
+        pandecode_log("},\n");
+}
+
+#define SHORT_SLIDE(num) \
+        pandecode_u32_slide(num, s->unknown ## num, ARRAY_SIZE(s->unknown ## num))
+
 static void
 pandecode_compute_fbd(uint64_t gpu_va, int job_no)
 {
@@ -548,12 +562,16 @@ pandecode_compute_fbd(uint64_t gpu_va, int job_no)
         pandecode_log("struct mali_compute_fbd framebuffer_%d = {\n", job_no);
         pandecode_indent++;
 
-        pandecode_log(".unknown = {");
-
-        for (int i = 0; i < sizeof(s->unknown) / sizeof(s->unknown[0]); ++i)
-                printf("%X, ", s->unknown[i]);
-
-        pandecode_log("},\n");
+        SHORT_SLIDE(1);
+        MEMORY_PROP(s, unknown2);
+        MEMORY_PROP(s, unknown3);
+        SHORT_SLIDE(4);
+        SHORT_SLIDE(5);
+        MEMORY_PROP(s, unknown6);
+        SHORT_SLIDE(7);
+        MEMORY_PROP(s, unknown8);
+        MEMORY_PROP(s, unknown9);
+        SHORT_SLIDE(10);
 
         pandecode_indent--;
         printf("},\n");