Mesa (master): v3d: Use the uniform pretty-printer in v3d_write_uniforms()'s debug code.

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Sat Dec 15 03:29:16 UTC 2018


Module: Mesa
Branch: master
Commit: a370ed76ab043ebcc1c4c866d3fef85c7dc77035
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=a370ed76ab043ebcc1c4c866d3fef85c7dc77035

Author: Eric Anholt <eric at anholt.net>
Date:   Tue Dec 11 22:43:56 2018 -0800

v3d: Use the uniform pretty-printer in v3d_write_uniforms()'s debug code.

This will be a lot easier than my usual "38400.000000?  that looks like a
viewport scale" decoding strategy.

---

 src/gallium/drivers/v3d/v3d_uniforms.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/gallium/drivers/v3d/v3d_uniforms.c b/src/gallium/drivers/v3d/v3d_uniforms.c
index eb8dffa185..bc680af095 100644
--- a/src/gallium/drivers/v3d/v3d_uniforms.c
+++ b/src/gallium/drivers/v3d/v3d_uniforms.c
@@ -303,9 +303,11 @@ v3d_write_uniforms(struct v3d_context *v3d, struct v3d_compiled_shader *shader,
                 }
 #if 0
                 uint32_t written_val = *((uint32_t *)uniforms - 1);
-                fprintf(stderr, "shader %p[%d]: 0x%08x / 0x%08x (%f)\n",
+                fprintf(stderr, "shader %p[%d]: 0x%08x / 0x%08x (%f) ",
                         shader, i, __gen_address_offset(&uniform_stream) + i * 4,
                         written_val, uif(written_val));
+                vir_dump_uniform(uinfo->contents[i], data);
+                fprintf(stderr, "\n");
 #endif
         }
 




More information about the mesa-commit mailing list