On Thu, Apr 28, 2016 at 11:26 AM, Ilia Mirkin <imir...@alum.mit.edu> wrote: > On Thu, Apr 28, 2016 at 11:21 AM, Connor Abbott <cwabbo...@gmail.com> wrote: >> On Thu, Apr 28, 2016 at 11:20 AM, Ilia Mirkin <imir...@alum.mit.edu> wrote: >>> What if the existing operations were already exact? >> >> They aren't -- the builder makes them non-exact by default, and we >> initialize the builder ourselves in this pass. > > Hmmmmmm... OK. I'm just thinking of the case > > precise c = op(a, b) > > And op gets lowered. The resulting operations should also be exact. If > that's what's happening, then all's well.
The resulting operations should be exact regardless of whether the original one was exact -- they're relying on the extra precision that fma() gives us in order to get the right precision in the result, and like in GLSL, there's no guarantee that a non-exact fma won't be split into multiply + add. Once we lower the operation, the compiler can't really apply any optimizations to the operation as a whole (except maybe constant folding) so it basically becomes exact anyways. > > -ilia _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev