i965/fs: don't use ir->type in emit_texture_gen4()
authorConnor Abbott <connor.abbott@intel.com>
Fri, 1 Aug 2014 23:30:26 +0000 (16:30 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 16 Oct 2014 00:05:05 +0000 (17:05 -0700)
We already have the type from the original destination.

Signed-off-by: Connor Abbott <connor.abbott@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Chris Forbes <chrisf@ijw.co.nz>
src/mesa/drivers/dri/i965/brw_fs_visitor.cpp

index 3096e3fd8d6a1106ef987321c3be68b3f0823c4f..c741ca34df19d16e60ad7fe325402b884065062d 100644 (file)
@@ -1296,10 +1296,7 @@ fs_visitor::emit_texture_gen4(ir_texture *ir, fs_reg dst,
        * this weirdness around to the expected layout.
        */
       orig_dst = dst;
-      dst = fs_reg(GRF, virtual_grf_alloc(8),
-                   (brw->is_g4x ?
-                    brw_type_for_base_type(ir->type) :
-                    BRW_REGISTER_TYPE_F));
+      dst = fs_reg(GRF, virtual_grf_alloc(8), orig_dst.type);
    }
 
    enum opcode opcode;