diff options
Diffstat (limited to 'src/gallium/drivers/svga/svga_tgsi.c')
-rw-r--r-- | src/gallium/drivers/svga/svga_tgsi.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/gallium/drivers/svga/svga_tgsi.c b/src/gallium/drivers/svga/svga_tgsi.c index 7396ad08e27..7cbd5166900 100644 --- a/src/gallium/drivers/svga/svga_tgsi.c +++ b/src/gallium/drivers/svga/svga_tgsi.c @@ -173,6 +173,8 @@ svga_tgsi_vgpu9_translate(struct svga_context *svga, struct svga_shader_variant *variant = NULL; struct svga_shader_emitter emit; + SVGA_STATS_TIME_PUSH(svga_sws(svga), SVGA_STATS_TIME_TGSIVGPU9TRANSLATE); + memset(&emit, 0, sizeof(emit)); emit.size = 1024; @@ -252,11 +254,15 @@ svga_tgsi_vgpu9_translate(struct svga_context *svga, } #endif - return variant; + goto done; - fail: +fail: FREE(variant); if (emit.buf != err_buf) FREE(emit.buf); - return NULL; + variant = NULL; + +done: + SVGA_STATS_TIME_POP(svga_sws(svga)); + return variant; } |