pan/midgard: Add OP_IS_DERIVATIVE helper
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Mon, 29 Jul 2019 23:52:55 +0000 (16:52 -0700)
committerAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Tue, 30 Jul 2019 17:01:19 +0000 (10:01 -0700)
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
src/panfrost/midgard/helpers.h

index 0cd2e71862c9ac466afbf0b30059425b4aa2f6ac..9e8f964b00cbff643b9cc7931e06bc108a0d5b7e 100644 (file)
                 op == midgard_alu_op_fcsel \
         )
 
+#define OP_IS_DERIVATIVE(op) ( \
+                op == TEXTURE_OP_DFDX || \
+                op == TEXTURE_OP_DFDY \
+        )
+
 /* ALU control words are single bit fields with a lot of space */
 
 #define ALU_ENAB_VEC_MUL  (1 << 17)