i965: Move debug_batch hook out of the vtable.
authorKenneth Graunke <kenneth@whitecape.org>
Sat, 29 Jun 2013 02:36:04 +0000 (19:36 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Wed, 3 Jul 2013 17:48:14 +0000 (10:48 -0700)
brw_debug_batch() is the only implementation of this function, so it
makes sense to just call it directly.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
src/mesa/drivers/dri/i965/brw_vtbl.c
src/mesa/drivers/dri/i965/intel_batchbuffer.c
src/mesa/drivers/dri/i965/intel_context.h

index e6f8456ba7fafc7400e16a4f52e51e3edd2670cb..fbf38f29b9e92e2c986e6fe36fb95a524c9ebb0b 100644 (file)
@@ -159,7 +159,6 @@ void brwInitVtbl( struct brw_context *brw )
    brw->intel.vtbl.new_batch = brw_new_batch;
    brw->intel.vtbl.finish_batch = brw_finish_batch;
    brw->intel.vtbl.destroy = brw_destroy_context;
-   brw->intel.vtbl.debug_batch = brw_debug_batch;
    brw->intel.vtbl.annotate_aub = brw_annotate_aub;
 
    assert(brw->intel.gen >= 4);
index a5386910e228a6f1a4d6ca52bcbec9d1acc0e04f..b782966ac2d13be716fe3f08119a85855943a689 100644 (file)
@@ -31,6 +31,7 @@
 #include "intel_reg.h"
 #include "intel_bufmgr.h"
 #include "intel_buffers.h"
+#include "brw_context.h"
 
 static void
 intel_batchbuffer_reset(struct intel_context *intel);
@@ -165,8 +166,7 @@ do_batch_dump(struct intel_context *intel)
    if (ret == 0) {
       drm_intel_bo_unmap(batch->bo);
 
-      if (intel->vtbl.debug_batch != NULL)
-        intel->vtbl.debug_batch(intel);
+      brw_debug_batch(intel);
    }
 }
 
index 97fdc9776ef68fc732717b576e4cd53458efee84..d3e09b73adcbcc6c13716e1ca74d1f7c474737c4 100644 (file)
@@ -119,7 +119,6 @@ struct intel_context
       void (*finish_batch) (struct intel_context * intel);
       void (*new_batch) (struct intel_context * intel);
 
-      void (*debug_batch)(struct intel_context *intel);
       void (*annotate_aub)(struct intel_context *intel);
 
       void (*update_texture_surface)(struct gl_context *ctx,