// generated by gen_elemwise_each_mode.py
#define MEGDNN_FOREACH_ELEMWISE_MODE_UNARY_BOOL(cb) MEGDNN_ELEMWISE_MODE_ENABLE(NOT, cb)

#define MEGDNN_FOREACH_ELEMWISE_MODE_UNARY_FLOAT(cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(RELU, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(ABS, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(NEGATE, cb)          \
    MEGDNN_ELEMWISE_MODE_ENABLE(ACOS, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(ASIN, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(CEIL, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(COS, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(EXP, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(EXPM1, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(FLOOR, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(LOG, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(LOG1P, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(SIGMOID, cb)         \
    MEGDNN_ELEMWISE_MODE_ENABLE(SIN, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(TANH, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(FAST_TANH, cb)       \
    MEGDNN_ELEMWISE_MODE_ENABLE(ROUND, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(ERF, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(ERFINV, cb)          \
    MEGDNN_ELEMWISE_MODE_ENABLE(ERFC, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(ERFCINV, cb)         \
    MEGDNN_ELEMWISE_MODE_ENABLE(H_SWISH, cb)         \
    MEGDNN_ELEMWISE_MODE_ENABLE(SILU, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(GELU, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(SINH, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(COSH, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(ASINH, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(ACOSH, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(ATANH, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(TAN, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(SOFTPLUS, cb)        \
    MEGDNN_ELEMWISE_MODE_ENABLE(RELU6, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(HSIGMOID, cb)        \
    MEGDNN_ELEMWISE_MODE_ENABLE(LOGSIGMOID, cb)      \
    MEGDNN_ELEMWISE_MODE_ENABLE(SQRT, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(SQUARE, cb)          \
    MEGDNN_ELEMWISE_MODE_ENABLE(SIGN, cb)

#define MEGDNN_FOREACH_ELEMWISE_MODE_UNARY_INT(cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(RELU, cb)          \
    MEGDNN_ELEMWISE_MODE_ENABLE(ABS, cb)           \
    MEGDNN_ELEMWISE_MODE_ENABLE(NEGATE, cb)        \
    MEGDNN_ELEMWISE_MODE_ENABLE(RELU6, cb)         \
    MEGDNN_ELEMWISE_MODE_ENABLE(SQUARE, cb)        \
    MEGDNN_ELEMWISE_MODE_ENABLE(SIGN, cb)

#define MEGDNN_FOREACH_ELEMWISE_MODE_BINARY_BOOL(cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(AND, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(OR, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(XOR, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(LT, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(LEQ, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(EQ, cb)

#define MEGDNN_FOREACH_ELEMWISE_MODE_BINARY_FLOAT(cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(ABS_GRAD, cb)         \
    MEGDNN_ELEMWISE_MODE_ENABLE(ADD, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(FLOOR_DIV, cb)        \
    MEGDNN_ELEMWISE_MODE_ENABLE(MAX, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(MIN, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(MOD, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(MUL, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(SIGMOID_GRAD, cb)     \
    MEGDNN_ELEMWISE_MODE_ENABLE(SUB, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(SWITCH_GT0, cb)       \
    MEGDNN_ELEMWISE_MODE_ENABLE(TANH_GRAD, cb)        \
    MEGDNN_ELEMWISE_MODE_ENABLE(LT, cb)               \
    MEGDNN_ELEMWISE_MODE_ENABLE(LEQ, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(EQ, cb)               \
    MEGDNN_ELEMWISE_MODE_ENABLE(FUSE_ADD_RELU, cb)    \
    MEGDNN_ELEMWISE_MODE_ENABLE(TRUE_DIV, cb)         \
    MEGDNN_ELEMWISE_MODE_ENABLE(POW, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(LOG_SUM_EXP, cb)      \
    MEGDNN_ELEMWISE_MODE_ENABLE(FUSE_ADD_TANH, cb)    \
    MEGDNN_ELEMWISE_MODE_ENABLE(FAST_TANH_GRAD, cb)   \
    MEGDNN_ELEMWISE_MODE_ENABLE(FUSE_ADD_SIGMOID, cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(ATAN2, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(H_SWISH_GRAD, cb)     \
    MEGDNN_ELEMWISE_MODE_ENABLE(FUSE_ADD_H_SWISH, cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(SILU_GRAD, cb)        \
    MEGDNN_ELEMWISE_MODE_ENABLE(GELU_GRAD, cb)        \
    MEGDNN_ELEMWISE_MODE_ENABLE(PRELU, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(ASINH_GRAD, cb)       \
    MEGDNN_ELEMWISE_MODE_ENABLE(ACOSH_GRAD, cb)       \
    MEGDNN_ELEMWISE_MODE_ENABLE(ATANH_GRAD, cb)       \
    MEGDNN_ELEMWISE_MODE_ENABLE(SOFTPLUS_GRAD, cb)    \
    MEGDNN_ELEMWISE_MODE_ENABLE(RELU6_GRAD, cb)       \
    MEGDNN_ELEMWISE_MODE_ENABLE(HSIGMOID_GRAD, cb)

#define MEGDNN_FOREACH_ELEMWISE_MODE_BINARY_INT(cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(ABS_GRAD, cb)       \
    MEGDNN_ELEMWISE_MODE_ENABLE(ADD, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(FLOOR_DIV, cb)      \
    MEGDNN_ELEMWISE_MODE_ENABLE(MAX, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(MIN, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(MOD, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(MUL, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(SIGMOID_GRAD, cb)   \
    MEGDNN_ELEMWISE_MODE_ENABLE(SUB, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(SWITCH_GT0, cb)     \
    MEGDNN_ELEMWISE_MODE_ENABLE(TANH_GRAD, cb)      \
    MEGDNN_ELEMWISE_MODE_ENABLE(LT, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(LEQ, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(EQ, cb)             \
    MEGDNN_ELEMWISE_MODE_ENABLE(FUSE_ADD_RELU, cb)  \
    MEGDNN_ELEMWISE_MODE_ENABLE(SHL, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(SHR, cb)            \
    MEGDNN_ELEMWISE_MODE_ENABLE(RMULH, cb)          \
    MEGDNN_ELEMWISE_MODE_ENABLE(PRELU, cb)

#define MEGDNN_FOREACH_ELEMWISE_MODE_TERNARY_BOOL(cb)

#define MEGDNN_FOREACH_ELEMWISE_MODE_TERNARY_FLOAT(cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(COND_LEQ_MOV, cb)      \
    MEGDNN_ELEMWISE_MODE_ENABLE(COND_LT_MOV, cb)       \
    MEGDNN_ELEMWISE_MODE_ENABLE(FUSE_MUL_ADD3, cb)     \
    MEGDNN_ELEMWISE_MODE_ENABLE(CLIP, cb)              \
    MEGDNN_ELEMWISE_MODE_ENABLE(PRELU_GRAD, cb)

#define MEGDNN_FOREACH_ELEMWISE_MODE_TERNARY_INT(cb) \
    MEGDNN_ELEMWISE_MODE_ENABLE(COND_LEQ_MOV, cb)    \
    MEGDNN_ELEMWISE_MODE_ENABLE(COND_LT_MOV, cb)     \
    MEGDNN_ELEMWISE_MODE_ENABLE(CLIP, cb)
