i965/vp: Fix crashes with INTEL_DEBUG=vs.
authorEric Anholt <eric@anholt.net>
Fri, 30 Nov 2012 21:02:11 +0000 (13:02 -0800)
committerEric Anholt <eric@anholt.net>
Mon, 3 Dec 2012 21:19:43 +0000 (13:19 -0800)
The VP generation doesn't set up the output reg strings, so if you
didn't happen to get these values as 0 on the stack, you'd lose.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp

index aaf932fa02db7de4cec81dbc1ee219520504b734..544974a9fdd5ec421ac254a130879a5b865abf34 100644 (file)
@@ -2824,6 +2824,7 @@ vec4_visitor::vec4_visitor(struct brw_context *brw,
 
    this->base_ir = NULL;
    this->current_annotation = NULL;
+   memset(this->output_reg_annotation, 0, sizeof(this->output_reg_annotation));
 
    this->c = c;
    this->vp = &c->vp->program;