Mesa (master): i965: Make sure that the shader_time report at context destroy happens.
Eric Anholt
anholt at kemper.freedesktop.org
Fri Dec 14 23:25:13 UTC 2012
Module: Mesa
Branch: master
Commit: 1315f3b4b38cb569846389fe3080ffa8ac6946d9
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=1315f3b4b38cb569846389fe3080ffa8ac6946d9
Author: Eric Anholt <eric at anholt.net>
Date: Fri Dec 14 14:02:34 2012 -0800
i965: Make sure that the shader_time report at context destroy happens.
Otherwise, you end up with some report from within a second of context
destroy, which is now what you really want for testing the impact of
changes
---
src/mesa/drivers/dri/i965/brw_vtbl.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_vtbl.c b/src/mesa/drivers/dri/i965/brw_vtbl.c
index f2f0e7b..237ec1e 100644
--- a/src/mesa/drivers/dri/i965/brw_vtbl.c
+++ b/src/mesa/drivers/dri/i965/brw_vtbl.c
@@ -71,6 +71,9 @@ static void brw_destroy_context( struct intel_context *intel )
struct brw_context *brw = brw_context(&intel->ctx);
if (INTEL_DEBUG & DEBUG_SHADER_TIME) {
+ /* Force a report. */
+ brw->shader_time.report_time = 0;
+
brw_collect_and_report_shader_time(brw);
brw_destroy_shader_time(brw);
}
More information about the mesa-commit
mailing list