On 09/04/2013 07:11 PM, Matt Turner wrote:
On Wed, Sep 4, 2013 at 3:22 PM, Kenneth Graunke <kenn...@whitecape.org> wrote:
dotlike() uses ir_binop_mul for scalars, and ir_binop_dot for vectors.

When generating built-in functions, we often want to use regular
multiply for scalar signatures, and dot() for vector signatures.
ir_binop_dot only works on vectors, so we have to switch opcodes,
even if the code is otherwise identical.  dotlike() makes this easy.

Why not just make dot() do this?

I wasn't sure how I felt about dot() returning something other than ir_binop_dot. But it kind of makes sense, so if people would prefer that, I'm fine with doing that instead.

--Ken
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to