summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2013-11-27 16:14:14 -0800
committerMatt Turner <[email protected]>2013-12-04 20:05:42 -0800
commitb1eb2ad8d159748034e7befc22b46a0b3b040186 (patch)
tree9c98e12ab29ceddc4915891671c25e7f3668a4a4 /src/mesa/drivers
parent04d83396eef7a8c8603f55bc0a0b04c80a9f6cf5 (diff)
i965: Allow commuting the operands of ADDC for const propagation.
Reviewed-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp2
-rw-r--r--src/mesa/drivers/dri/i965/brw_vec4_copy_propagation.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp b/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp
index a1720cdd1a0..fc47d22a182 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp
@@ -348,7 +348,6 @@ fs_visitor::try_constant_propagate(fs_inst *inst, acp_entry *entry)
case BRW_OPCODE_ASR:
case BRW_OPCODE_SHL:
case BRW_OPCODE_SHR:
- case BRW_OPCODE_ADDC:
case BRW_OPCODE_SUBB:
if (i == 1) {
inst->src[i] = entry->src;
@@ -362,6 +361,7 @@ fs_visitor::try_constant_propagate(fs_inst *inst, acp_entry *entry)
case BRW_OPCODE_OR:
case BRW_OPCODE_AND:
case BRW_OPCODE_XOR:
+ case BRW_OPCODE_ADDC:
if (i == 1) {
inst->src[i] = entry->src;
progress = true;
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_copy_propagation.cpp b/src/mesa/drivers/dri/i965/brw_vec4_copy_propagation.cpp
index c9c739080ca..c8feff84d56 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_copy_propagation.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_copy_propagation.cpp
@@ -99,7 +99,6 @@ try_constant_propagation(vec4_instruction *inst, int arg, src_reg *values[4])
case BRW_OPCODE_ASR:
case BRW_OPCODE_SHL:
case BRW_OPCODE_SHR:
- case BRW_OPCODE_ADDC:
case BRW_OPCODE_SUBB:
if (arg == 1) {
inst->src[arg] = value;
@@ -113,6 +112,7 @@ try_constant_propagation(vec4_instruction *inst, int arg, src_reg *values[4])
case BRW_OPCODE_OR:
case BRW_OPCODE_AND:
case BRW_OPCODE_XOR:
+ case BRW_OPCODE_ADDC:
if (arg == 1) {
inst->src[arg] = value;
return true;