[Mesa-dev] [PATCH 2/3] i965/fs: Don't propagate saturate modifiers into partial writes.

Matt Turner mattst88 at gmail.com
Thu Apr 3 17:30:03 PDT 2014


---
 src/mesa/drivers/dri/i965/brw_fs_saturate_propagation.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/mesa/drivers/dri/i965/brw_fs_saturate_propagation.cpp b/src/mesa/drivers/dri/i965/brw_fs_saturate_propagation.cpp
index eaecb45..4f3dcff 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_saturate_propagation.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_saturate_propagation.cpp
@@ -59,7 +59,8 @@ opt_saturate_propagation_local(fs_visitor *v, bblock_t *block)
 
          if (scan_inst->dst.file == GRF &&
              scan_inst->dst.reg == inst->src[0].reg &&
-             scan_inst->dst.reg_offset == inst->src[0].reg_offset) {
+             scan_inst->dst.reg_offset == inst->src[0].reg_offset &&
+             !scan_inst->is_partial_write()) {
             if (scan_inst->can_do_saturate()) {
                scan_inst->saturate = true;
                inst->saturate = false;
-- 
1.8.3.2



More information about the mesa-dev mailing list