lima: Lower nir_op_idiv with other scalar math operations.

This will end up appearing in the backend once we move GLSL's
idiv->fmul+frcp lowering to NIR.

Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16823>
This commit is contained in:
Vasily Khoruzhick 2022-06-06 14:43:43 -07:00 committed by Marge Bot
parent 5c499d6d1a
commit 5ec0301ec7

View file

@ -166,6 +166,10 @@ lima_alu_to_scalar_filter_cb(const nir_instr *instr, const void *data)
nir_alu_instr *alu = nir_instr_as_alu(instr);
switch (alu->op) {
case nir_op_frcp:
/* nir_op_idiv is lowered to frcp by lower_int_to_floats which
* will be run later, so lower idiv here
*/
case nir_op_idiv:
case nir_op_frsq:
case nir_op_flog2:
case nir_op_fexp2: