<p dir="ltr"><br>
On Sep 2, 2015 10:43 AM, "Mark Janes" <<a href="mailto:mark.a.janes@intel.com">mark.a.janes@intel.com</a>> wrote:<br>
><br>
> Kenneth Graunke <<a href="mailto:kenneth@whitecape.org">kenneth@whitecape.org</a>> writes:<br>
><br>
> > On Wednesday, September 02, 2015 12:03:12 AM Matt Turner wrote:<br>
> >> The lowered code reads from the destination, which isn't possible from<br>
> >> message registers.<br>
> >><br>
> >> Fixes the dEQP functional.shaders.precision.int.highp_mul_fragment test<br>
> >> on SNB.<br>
> >> ---<br>
> >> src/mesa/drivers/dri/i965/brw_fs.cpp | 8 ++++----<br>
> >> 1 file changed, 4 insertions(+), 4 deletions(-)<br>
> >><br>
> >> diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp<br>
> >> index 269914d..e28eb5d 100644<br>
> >> --- a/src/mesa/drivers/dri/i965/brw_fs.cpp<br>
> >> +++ b/src/mesa/drivers/dri/i965/brw_fs.cpp<br>
> >> @@ -3192,7 +3192,8 @@ fs_visitor::lower_integer_multiplication()<br>
> >> * schedule multi-component multiplications much better.<br>
> >> */<br>
> >><br>
> >> - if (inst->conditional_mod && inst->dst.is_null()) {<br>
> >> + fs_reg orig_dst = inst->dst;<br>
> >> + if (orig_dst.is_null() || orig_dst.file == MRF) {<br>
> >> inst->dst = fs_reg(GRF, alloc.allocate(dispatch_width / 8),<br>
> >> inst->dst.type);<br>
> >> }<br>
> >> @@ -3258,10 +3259,9 @@ fs_visitor::lower_integer_multiplication()<br>
> >><br>
> >> ibld.ADD(dst, low, high);<br>
> >><br>
> >> - if (inst->conditional_mod) {<br>
> >> - fs_reg null(retype(ibld.null_reg_f(), inst->dst.type));<br>
> >> + if (inst->conditional_mod || orig_dst.file == MRF) {<br>
> >> set_condmod(inst->conditional_mod,<br>
> >> - ibld.MOV(null, inst->dst));<br>
> >> + ibld.MOV(orig_dst, inst->dst));<br>
> >> }<br>
> >> }<br>
> >><br>
> >><br>
> ><br>
> > Cc: "10.6 11.0" <<a href="mailto:mesa-stable@lists.freedesktop.org">mesa-stable@lists.freedesktop.org</a>><br>
> > Reviewed-by: Kenneth Graunke <<a href="mailto:kenneth@whitecape.org">kenneth@whitecape.org</a>><br>
><br>
> The second hunk doesn't apply to 10.6.</p>
<p dir="ltr">That's because this patch uses fs_builder which didn't exist in 10.6. It should be an easy back-port.<br>
</p>