OP_AND,
OP_OR,
OP_XOR,
+ OP_LOP3_LUT,
OP_SHL,
OP_SHR,
OP_MAX,
#define NV50_IR_SUBOP_VOTE_ALL 0
#define NV50_IR_SUBOP_VOTE_ANY 1
#define NV50_IR_SUBOP_VOTE_UNI 2
+#define NV50_IR_SUBOP_LOP3_LUT_SRC0 0xf0
+#define NV50_IR_SUBOP_LOP3_LUT_SRC1 0xcc
+#define NV50_IR_SUBOP_LOP3_LUT_SRC2 0xaa
+#define NV50_IR_SUBOP_LOP3_LUT(exp) ({ \
+ uint8_t a = NV50_IR_SUBOP_LOP3_LUT_SRC0; \
+ uint8_t b = NV50_IR_SUBOP_LOP3_LUT_SRC1; \
+ uint8_t c = NV50_IR_SUBOP_LOP3_LUT_SRC2; \
+ (uint8_t)(exp); \
+})
#define NV50_IR_SUBOP_MINMAX_LOW 1
#define NV50_IR_SUBOP_MINMAX_MED 2
2, 2, 2, 2, 2, 3, 3, 3, // ADD, SUB, MUL, DIV, MOD, MAD, FMA, SAD
3, 3, // SHLADD, XMAD
1, 1, 1, // ABS, NEG, NOT
- 2, 2, 2, 2, 2, // AND, OR, XOR, SHL, SHR
+ 2, 2, 2, 3, 2, 2, // AND, OR, XOR, LOP3_LUT, SHL, SHR
2, 2, 1, // MAX, MIN, SAT
1, 1, 1, 1, // CEIL, FLOOR, TRUNC, CVT
3, 3, 3, 2, 3, 3, // SET_AND,OR,XOR, SET, SELP, SLCT
OPCLASS_ARITH, OPCLASS_ARITH, OPCLASS_ARITH,
OPCLASS_ARITH, OPCLASS_ARITH,
OPCLASS_ARITH, OPCLASS_ARITH, OPCLASS_ARITH, OPCLASS_ARITH, OPCLASS_ARITH,
- // ABS, NEG; NOT, AND, OR, XOR; SHL, SHR
+ // ABS, NEG; NOT, AND, OR, XOR, LOP3_LUT; SHL, SHR
OPCLASS_CONVERT, OPCLASS_CONVERT,
- OPCLASS_LOGIC, OPCLASS_LOGIC, OPCLASS_LOGIC, OPCLASS_LOGIC,
+ OPCLASS_LOGIC, OPCLASS_LOGIC, OPCLASS_LOGIC, OPCLASS_LOGIC, OPCLASS_LOGIC,
OPCLASS_SHIFT, OPCLASS_SHIFT,
// MAX, MIN
OPCLASS_COMPARE, OPCLASS_COMPARE,