Mesa (master): intel/fs: Only propagate saturation if exec_size is the same.

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Apr 22 23:56:26 UTC 2019


Module: Mesa
Branch: master
Commit: 0778748ebadca7991c541ec674024c2bec5f08f5
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=0778748ebadca7991c541ec674024c2bec5f08f5

Author: Rafael Antognolli <rafael.antognolli at intel.com>
Date:   Fri Oct 19 15:33:50 2018 -0700

intel/fs: Only propagate saturation if exec_size is the same.

Otherwise it could propagate the saturation from a SIMD16 instruction
into a SIMD8 instruction. With that, only part of the destination
register, which is the source of the move with saturation, would have
been updated.

Reviewed-by: Matt Turner <mattst88 at gmail.com>

---

 src/intel/compiler/brw_fs_saturate_propagation.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/intel/compiler/brw_fs_saturate_propagation.cpp b/src/intel/compiler/brw_fs_saturate_propagation.cpp
index 1e1461063ae..fe3fa7ecfea 100644
--- a/src/intel/compiler/brw_fs_saturate_propagation.cpp
+++ b/src/intel/compiler/brw_fs_saturate_propagation.cpp
@@ -65,7 +65,8 @@ opt_saturate_propagation_local(fs_visitor *v, bblock_t *block,
 
       bool interfered = false;
       foreach_inst_in_block_reverse_starting_from(fs_inst, scan_inst, inst) {
-         if (regions_overlap(scan_inst->dst, scan_inst->size_written,
+         if (scan_inst->exec_size == inst->exec_size &&
+             regions_overlap(scan_inst->dst, scan_inst->size_written,
                              inst->src[0], inst->size_read(0))) {
             if (scan_inst->is_partial_var_write(dispatch_width) ||
                 (scan_inst->dst.type != inst->dst.type &&




More information about the mesa-commit mailing list