i965: Drop INTEL_DEBUG=stats.

For whatever reason, we had an INTEL_DEBUG=stats option that enabled
various statistics counters on Gen4-5 systems.  It's been around
forever, though I can't think of a single time that it's been useful.

On Gen6+, we enable statistics all the time because they're necessary
to support various query object targets.  Turning them off would break
those queries.

Gen4-5 don't support those queries, so the statistics counters generally
aren't useful; we disabled them by default.  This patch disables them
altogether.

Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
This commit is contained in:
Kenneth Graunke
2017-05-08 23:53:36 -07:00
parent 31abfd2d35
commit 620f12a53f
9 changed files with 3 additions and 18 deletions

View File

@@ -195,7 +195,6 @@ See the <a href="xlibdriver.html">Xlib software driver page</a> for details.
<li>spill_fs - force spilling of all registers in the scalar backend (useful to debug spilling code)</li> <li>spill_fs - force spilling of all registers in the scalar backend (useful to debug spilling code)</li>
<li>spill_vec4 - force spilling of all registers in the vec4 backend (useful to debug spilling code)</li> <li>spill_vec4 - force spilling of all registers in the vec4 backend (useful to debug spilling code)</li>
<li>state - emit messages about state flag tracking</li> <li>state - emit messages about state flag tracking</li>
<li>stats - enable statistics counters. you probably actually want perfmon or intel_gpu_top instead.</li>
<li>sync - after sending each batch, emit a message and wait for that batch to finish rendering</li> <li>sync - after sending each batch, emit a message and wait for that batch to finish rendering</li>
<li>tcs - dump shader assembly for tessellation control shaders</li> <li>tcs - dump shader assembly for tessellation control shaders</li>
<li>tes - dump shader assembly for tessellation evaluation shaders</li> <li>tes - dump shader assembly for tessellation evaluation shaders</li>

View File

@@ -57,7 +57,6 @@ static const struct debug_control debug_control[] = {
{ "vert", DEBUG_VERTS }, { "vert", DEBUG_VERTS },
{ "dri", DEBUG_DRI }, { "dri", DEBUG_DRI },
{ "sf", DEBUG_SF }, { "sf", DEBUG_SF },
{ "stats", DEBUG_STATS },
{ "wm", DEBUG_WM }, { "wm", DEBUG_WM },
{ "urb", DEBUG_URB }, { "urb", DEBUG_URB },
{ "vs", DEBUG_VS }, { "vs", DEBUG_VS },

View File

@@ -57,7 +57,7 @@ extern uint64_t INTEL_DEBUG;
#define DEBUG_VERTS (1ull << 13) #define DEBUG_VERTS (1ull << 13)
#define DEBUG_DRI (1ull << 14) #define DEBUG_DRI (1ull << 14)
#define DEBUG_SF (1ull << 15) #define DEBUG_SF (1ull << 15)
#define DEBUG_STATS (1ull << 16) /* Hole - feel free to reuse (1ull << 16) */
#define DEBUG_WM (1ull << 17) #define DEBUG_WM (1ull << 17)
#define DEBUG_URB (1ull << 18) #define DEBUG_URB (1ull << 18)
#define DEBUG_VS (1ull << 19) #define DEBUG_VS (1ull << 19)

View File

@@ -226,7 +226,7 @@ static void upload_cc_unit(struct brw_context *brw)
cc->cc2.depth_write_enable = brw_depth_writes_enabled(brw); cc->cc2.depth_write_enable = brw_depth_writes_enabled(brw);
} }
if (brw->stats_wm || unlikely(INTEL_DEBUG & DEBUG_STATS)) if (brw->stats_wm)
cc->cc5.statistics_enable = 1; cc->cc5.statistics_enable = 1;
/* BRW_NEW_CC_VP */ /* BRW_NEW_CC_VP */

View File

@@ -114,9 +114,6 @@ brw_upload_clip_unit(struct brw_context *brw)
clip->thread4.max_threads = 1 - 1; clip->thread4.max_threads = 1 - 1;
} }
if (unlikely(INTEL_DEBUG & DEBUG_STATS))
clip->thread4.stats_enable = 1;
/* _NEW_TRANSFORM */ /* _NEW_TRANSFORM */
if (brw->gen == 5 || brw->is_g4x) if (brw->gen == 5 || brw->is_g4x)
clip->clip5.userclip_enable_flags = ctx->Transform.ClipPlanesEnabled; clip->clip5.userclip_enable_flags = ctx->Transform.ClipPlanesEnabled;

View File

@@ -80,9 +80,6 @@ brw_upload_gs_unit(struct brw_context *brw)
if (brw->gen == 5) if (brw->gen == 5)
gs->thread4.rendering_enable = 1; gs->thread4.rendering_enable = 1;
if (unlikely(INTEL_DEBUG & DEBUG_STATS))
gs->thread4.stats_enable = 1;
/* BRW_NEW_VIEWPORT_COUNT */ /* BRW_NEW_VIEWPORT_COUNT */
gs->gs6.max_vp_index = brw->clip.viewport_count - 1; gs->gs6.max_vp_index = brw->clip.viewport_count - 1;

View File

@@ -174,9 +174,6 @@ static void upload_sf_unit( struct brw_context *brw )
sf->thread4.max_threads = MIN2(chipset_max_threads, sf->thread4.max_threads = MIN2(chipset_max_threads,
brw->urb.nr_sf_entries) - 1; brw->urb.nr_sf_entries) - 1;
if (unlikely(INTEL_DEBUG & DEBUG_STATS))
sf->thread4.stats_enable = 1;
/* BRW_NEW_SF_VP */ /* BRW_NEW_SF_VP */
sf->sf5.sf_viewport_state_offset = (brw->batch.bo->offset64 + sf->sf5.sf_viewport_state_offset = (brw->batch.bo->offset64 +
brw->sf.vp_offset) >> 5; /* reloc */ brw->sf.vp_offset) >> 5; /* reloc */

View File

@@ -146,10 +146,6 @@ brw_upload_vs_unit(struct brw_context *brw)
vs->vs5.sampler_count = (stage_state->sampler_count + 3) / 4; vs->vs5.sampler_count = (stage_state->sampler_count + 3) / 4;
} }
if (unlikely(INTEL_DEBUG & DEBUG_STATS))
vs->thread4.stats_enable = 1;
/* Vertex program always enabled: /* Vertex program always enabled:
*/ */
vs->vs6.vs_enable = 1; vs->vs6.vs_enable = 1;

View File

@@ -217,7 +217,7 @@ brw_upload_wm_unit(struct brw_context *brw)
wm->wm5.line_stipple = ctx->Line.StippleFlag; wm->wm5.line_stipple = ctx->Line.StippleFlag;
/* BRW_NEW_STATS_WM */ /* BRW_NEW_STATS_WM */
if (unlikely(INTEL_DEBUG & DEBUG_STATS) || brw->stats_wm) if (brw->stats_wm)
wm->wm4.stats_enable = 1; wm->wm4.stats_enable = 1;
/* Emit scratch space relocation */ /* Emit scratch space relocation */