[Mesa-dev] [PATCH 7/7] ir_to_mesa: Don't set component for ir_dereference in ir_quadop_vector

Kenneth Graunke kenneth at whitecape.org
Fri Jul 27 10:49:25 PDT 2012


From: Ian Romanick <ian.d.romanick at intel.com>

There can only be one variable used in an ir_quadop_vector.  Accesses
of this variable must be swizzled.  The component should have already
been set by the ir_type_swizzle handler.  Setting the component to
SWIZZLE_X here would overwrite whatever the ir_type_swizzle handler
had previously written.

Signed-off-by: Ian Romanick <ian.d.romanick at intel.com>
---
 src/mesa/program/ir_to_mesa.cpp | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/mesa/program/ir_to_mesa.cpp b/src/mesa/program/ir_to_mesa.cpp
index baa3172..0914f35 100644
--- a/src/mesa/program/ir_to_mesa.cpp
+++ b/src/mesa/program/ir_to_mesa.cpp
@@ -1014,7 +1014,6 @@ ir_to_mesa_visitor::emit_swz(ir_expression *ir)
 	       (ir_dereference_variable *) op;
 
 	    assert((var == NULL) || (deref->var == var));
-	    components[i] = SWIZZLE_X;
 	    var = deref->var;
 	    op = NULL;
 	    break;
-- 
1.7.11.3



More information about the mesa-dev mailing list