On Thu, Jul 9, 2015 at 4:11 PM, Francisco Jerez <curroje...@riseup.net> wrote: > Ilia Mirkin <imir...@alum.mit.edu> writes: > >> FYI there's already a lowering pass that does this in the GLSL IR >> (CARRY_TO_ARITH in lower_instructions). Perhaps the right place to do >> this is NIR though, just wanted to let you know. >> > Ah, I wasn't aware of that flag, that seems even better. I just tried > it and it seems to generate one instruction more per op than my assembly > code (apparently because our implementation of b2i is suboptimal, could > probably be fixed), but it would also work to get rid of the no16() > calls, which is all I care about right now. > > I'll resend using your approach tomorrow.
Ideally nir would be smart enough to combine ops back into carry/borrow ops in its algebraic pass (assuming backend support for GS5), which should hopefully allow CSE to also operate properly here. Cheers, -ilia _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev