From: Eric Anholt Date: Thu, 3 Jun 2010 17:13:18 +0000 (-0700) Subject: ir_to_mesa: Don't allocate temps for swizzles. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=4006424f5b5b3b189209faf03f2335f45c22b148;p=mesa.git ir_to_mesa: Don't allocate temps for swizzles. We do them in place by actually, you know, swizzling. --- diff --git a/ir_to_mesa.cpp b/ir_to_mesa.cpp index 56815ac8e1a..53b7337d64b 100644 --- a/ir_to_mesa.cpp +++ b/ir_to_mesa.cpp @@ -669,9 +669,8 @@ ir_to_mesa_visitor::visit(ir_swizzle *ir) */ ir->val->accept(this); - assert(this->result.file != PROGRAM_UNDEFINED); - - src_reg = this->get_temp(4); + src_reg = this->result; + assert(src_reg.file != PROGRAM_UNDEFINED); for (i = 0; i < 4; i++) { if (i < ir->type->vector_elements) {