i965: remove unneeded src_reg copy in emit_shader_time_write
authorEmil Velikov <emil.l.velikov@gmail.com>
Wed, 7 Oct 2015 11:38:12 +0000 (12:38 +0100)
committerKenneth Graunke <kenneth@whitecape.org>
Wed, 28 Oct 2015 09:28:38 +0000 (02:28 -0700)
The variable is already of type src_reg. creating a new instance only to
destroy it seems unnecessary.

Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/brw_vec4.cpp

index 71a5a4403f473d2f93074482d088a8cd6e5f0e35..f87b86fbd3e2c190b3c4155924dd6a3a322a8800 100644 (file)
@@ -1788,7 +1788,7 @@ vec4_visitor::emit_shader_time_write(int shader_time_subindex, src_reg value)
    emit(MOV(offset, src_reg(index * SHADER_TIME_STRIDE)));
 
    time.type = BRW_REGISTER_TYPE_UD;
-   emit(MOV(time, src_reg(value)));
+   emit(MOV(time, value));
 
    vec4_instruction *inst =
       emit(SHADER_OPCODE_SHADER_TIME_ADD, dst_reg(), src_reg(dst));