i965/peephole_ffma: Don't fuse exact adds
authorJason Ekstrand <jason.ekstrand@intel.com>
Thu, 17 Mar 2016 20:39:07 +0000 (13:39 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Wed, 23 Mar 2016 23:28:06 +0000 (16:28 -0700)
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
src/mesa/drivers/dri/i965/brw_nir_opt_peephole_ffma.c

index 49810c22cfa9415718abd53eeb1e172dcb4f5bf9..6e8b1f99505f83fe34d212d0d29072957d48628e 100644 (file)
@@ -168,7 +168,9 @@ brw_nir_opt_peephole_ffma_block(nir_block *block, void *void_state)
       if (add->op != nir_op_fadd)
          continue;
 
-      /* TODO: Maybe bail if this expression is considered "precise"? */
+      assert(add->dest.dest.is_ssa);
+      if (add->exact)
+         continue;
 
       assert(add->src[0].src.is_ssa && add->src[1].src.is_ssa);