dump command buffer
authorAlex Deucher <alexdeucher@gmail.com>
Wed, 3 Jun 2009 18:29:06 +0000 (14:29 -0400)
committerAlex Deucher <alexdeucher@gmail.com>
Wed, 3 Jun 2009 18:29:06 +0000 (14:29 -0400)
src/mesa/drivers/dri/r600/r600_cmdbuf.c

index 72a2ac1a8fc74bb5c188f6fa58edd536406d4035..5edc42b532725bb804b162eb2a6235fc56bcba5e 100644 (file)
@@ -350,6 +350,17 @@ static int r600_cs_set_age(struct radeon_cs *cs) /* -------------- */
     return 0;
 }
 
+static void dump_cmdbuf(struct radeon_cs *cs)
+{
+       int i;
+       fprintf(stderr,"--start--\n");
+       for (i = 0; i < cs->cdw; i++){
+               fprintf(stderr,"0x%08x\n", cs->packets[i]);
+       }
+       fprintf(stderr,"--end--\n");
+
+}
+
 static int r600_cs_emit(struct radeon_cs *cs)
 {
     struct r600_cs_manager_legacy *csm = (struct r600_cs_manager_legacy*)cs->csm;
@@ -391,7 +402,7 @@ static int r600_cs_emit(struct radeon_cs *cs)
     /* cs_cmd.cs_id      = 0; */
     cs_cmd.chunks     = (uint64_t)(unsigned long)chunk_ptrs;
 
-    /* dump_cmdbuf(cs); */
+    dump_cmdbuf(cs);
 
     do 
     {