i915: fix warning
authorKeith Whitwell <keith@tungstengraphics.com>
Thu, 1 May 2008 17:49:52 +0000 (18:49 +0100)
committerKeith Whitwell <keith@tungstengraphics.com>
Thu, 1 May 2008 19:49:44 +0000 (20:49 +0100)
src/gallium/drivers/i915simple/i915_debug_fp.c

index 37a3508fe14e34cbef706e7afea99a8cf3f84198..c024a051a586efa8198e9bca3b82fa477e704bb5 100644 (file)
@@ -333,12 +333,11 @@ void
 i915_disassemble_program(struct debug_stream *stream, 
                         const unsigned * program, unsigned sz)
 {
-   unsigned size = program[0] & 0x1ff;
    unsigned i;
 
    PRINTF(stream, "\t\tBEGIN\n");
 
-   assert(size + 2 == sz);
+   assert((program[0] & 0x1ff) + 2 == sz);
 
    program++;
    for (i = 1; i < sz; i += 3, program += 3) {