Mesa (master): vc4: Drop the dump_fbo() routine.

Eric Anholt anholt at kemper.freedesktop.org
Tue Aug 12 21:22:19 UTC 2014


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

Author: Eric Anholt <eric at anholt.net>
Date:   Mon Aug 11 12:47:30 2014 -0700

vc4: Drop the dump_fbo() routine.

Now that eglkms is working, and some tests are working under
PIGLIT_PLATFORM=gbm, I don't think I need this any more.

---

 src/gallium/drivers/vc4/vc4_context.c |   50 ---------------------------------
 1 file changed, 50 deletions(-)

diff --git a/src/gallium/drivers/vc4/vc4_context.c b/src/gallium/drivers/vc4/vc4_context.c
index 8ca4031..8073e79 100644
--- a/src/gallium/drivers/vc4/vc4_context.c
+++ b/src/gallium/drivers/vc4/vc4_context.c
@@ -37,54 +37,6 @@
 #include "vc4_resource.h"
 
 static void
-dump_fbo(struct vc4_context *vc4, struct vc4_bo *fbo)
-{
-#ifndef USE_VC4_SIMULATOR
-        uint32_t *map = vc4_bo_map(fbo);
-        uint32_t width = vc4->framebuffer.width;
-        uint32_t height = vc4->framebuffer.height;
-        uint32_t chunk_w = width / 79;
-        uint32_t chunk_h = height / 40;
-        uint32_t found_colors[10];
-        uint32_t num_found_colors = 0;
-
-        for (int by = 0; by < height; by += chunk_h) {
-                for (int bx = 0; bx < width; bx += chunk_w) {
-                        bool on = false, black = false;
-
-                        for (int y = by; y < MIN2(height, by + chunk_h); y++) {
-                                for (int x = bx; x < MIN2(width, bx + chunk_w); x++) {
-                                        uint32_t pix = map[y * width + x];
-                                        on |= pix != 0;
-                                        black |= pix == 0xff000000;
-
-                                        int i;
-                                        for (i = 0; i < num_found_colors; i++) {
-                                                if (pix == found_colors[i])
-                                                        break;
-                                        }
-                                        if (i == num_found_colors &&
-                                            num_found_colors < Elements(found_colors))
-                                                found_colors[num_found_colors++] = pix;
-                                }
-                        }
-                        if (black)
-                                fprintf(stderr, "O");
-                        else if (on)
-                                fprintf(stderr, "X");
-                        else
-                                fprintf(stderr, ".");
-                }
-                fprintf(stderr, "\n");
-        }
-
-        for (int i = 0; i < num_found_colors; i++) {
-                fprintf(stderr, "color %d: 0x%08x\n", i, found_colors[i]);
-        }
-#endif
-}
-
-static void
 vc4_setup_rcl(struct vc4_context *vc4)
 {
         struct vc4_surface *csurf = vc4_surface(vc4->framebuffer.cbufs[0]);
@@ -239,8 +191,6 @@ vc4_flush(struct pipe_context *pctx)
         vc4->dirty = ~0;
         vc4->resolve = 0;
         vc4->cleared = 0;
-
-        dump_fbo(vc4, ctex->bo);
 }
 
 static void




More information about the mesa-commit mailing list