Mesa (master): i965g: Silence printf format warnings on 64-bit builds.

Vinson Lee vlee at kemper.freedesktop.org
Sun Aug 22 05:46:28 UTC 2010


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

Author: Vinson Lee <vlee at vmware.com>
Date:   Sat Aug 21 22:45:09 2010 -0700

i965g: Silence printf format warnings on 64-bit builds.

---

 src/gallium/drivers/i965/brw_wm_debug.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/gallium/drivers/i965/brw_wm_debug.c b/src/gallium/drivers/i965/brw_wm_debug.c
index e276726..1b2aa93 100644
--- a/src/gallium/drivers/i965/brw_wm_debug.c
+++ b/src/gallium/drivers/i965/brw_wm_debug.c
@@ -101,16 +101,16 @@ void brw_wm_print_value( struct brw_wm_compile *c,
       debug_printf("undef");
    else if( value - c->vreg >= 0 &&
 	    value - c->vreg < BRW_WM_MAX_VREG)
-      debug_printf("r%d", value - c->vreg);
+      debug_printf("r%ld", (long) (value - c->vreg));
    else if (value - c->creg >= 0 &&
 	    value - c->creg < BRW_WM_MAX_PARAM)
-      debug_printf("c%d", value - c->creg);
+      debug_printf("c%ld", (long) (value - c->creg));
    else if (value - c->payload.input_interp >= 0 &&
 	    value - c->payload.input_interp < PIPE_MAX_SHADER_INPUTS)
-      debug_printf("i%d", value - c->payload.input_interp);
+      debug_printf("i%ld", (long) (value - c->payload.input_interp));
    else if (value - c->payload.depth >= 0 &&
 	    value - c->payload.depth < PIPE_MAX_SHADER_INPUTS)
-      debug_printf("d%d", value - c->payload.depth);
+      debug_printf("d%ld", (long) (value - c->payload.depth));
    else 
       debug_printf("?");
 }




More information about the mesa-commit mailing list