From 09454f68e5d5f267b1d76d1cde4ff8e2a91e105c Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Thu, 5 Nov 2009 12:35:22 +0000 Subject: [PATCH] i965g: hook up dumpers in dumping winsys --- src/gallium/winsys/drm/i965/xlib/xlib_i965.c | 61 ++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/src/gallium/winsys/drm/i965/xlib/xlib_i965.c b/src/gallium/winsys/drm/i965/xlib/xlib_i965.c index 4fe5db40330..b1edca818a1 100644 --- a/src/gallium/winsys/drm/i965/xlib/xlib_i965.c +++ b/src/gallium/winsys/drm/i965/xlib/xlib_i965.c @@ -43,6 +43,7 @@ #include "i965/brw_winsys.h" #include "i965/brw_screen.h" #include "i965/brw_reg.h" +#include "i965/brw_structs_dump.h" #define MAX_VRAM (128*1024*1024) @@ -234,6 +235,66 @@ xlib_brw_bo_subdata(struct brw_winsys_buffer *buffer, __FUNCTION__, (void *)buffer, offset, size, data, data_types[data_type]); + switch (data_type) { + case BRW_DATA_GS_CC_VP: + brw_dump_cc_viewport( data ); + break; + case BRW_DATA_GS_CC_UNIT: + brw_dump_cc_unit_state( data ); + break; + case BRW_DATA_GS_WM_PROG: + /* disassem */ + break; + case BRW_DATA_GS_SAMPLER_DEFAULT_COLOR: + brw_dump_sampler_default_color( data ); + break; + case BRW_DATA_GS_SAMPLER: + brw_dump_sampler_state( data ); + break; + case BRW_DATA_GS_WM_UNIT: + brw_dump_wm_unit_state( data ); + break; + case BRW_DATA_GS_SF_PROG: + /* disassem */ + break; + case BRW_DATA_GS_SF_VP: + brw_dump_sf_viewport( data ); + break; + case BRW_DATA_GS_SF_UNIT: + brw_dump_sf_unit_state( data ); + break; + case BRW_DATA_GS_VS_UNIT: + brw_dump_vs_unit_state( data ); + break; + case BRW_DATA_GS_VS_PROG: + /* disassem */ + break; + case BRW_DATA_GS_GS_UNIT: + brw_dump_gs_unit_state( data ); + break; + case BRW_DATA_GS_GS_PROG: + /* disassem */ + break; + case BRW_DATA_GS_CLIP_VP: + brw_dump_clipper_viewport( data ); + break; + case BRW_DATA_GS_CLIP_UNIT: + brw_dump_clip_unit_state( data ); + break; + case BRW_DATA_GS_CLIP_PROG: + break; + case BRW_DATA_SS_SURFACE: + brw_dump_surface_state( data ); + break; + case BRW_DATA_SS_SURF_BIND: + break; + case BRW_DATA_OTHER: + break; + default: + assert(0); + break; + } + memcpy(buf->virtual + offset, data, size); return 0; } -- 2.30.2