[Mesa-dev] [PATCH 6/9] i965/vec4: Don't constant propagate saturated values

Jason Ekstrand jason at jlekstrand.net
Thu Mar 17 17:21:43 UTC 2016


The FS backend bails as well.
---
 src/mesa/drivers/dri/i965/brw_vec4_copy_propagation.cpp | 3 +++
 1 file changed, 3 insertions(+)

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 92423e1..2dfe623 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_copy_propagation.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_copy_propagation.cpp
@@ -149,6 +149,9 @@ try_constant_propagate(const struct brw_device_info *devinfo,
    if (value.file != IMM)
       return false;
 
+   if (entry->saturatemask)
+      return false;
+
    if (value.type == BRW_REGISTER_TYPE_VF) {
       /* The result of bit-casting the component values of a vector float
        * cannot in general be represented as an immediate.
-- 
2.5.0.400.gff86faf



More information about the mesa-dev mailing list