Searched refs:is_constant_value (Results 1 – 2 of 2) sorted by relevance
/third_party/skia/src/sksl/ |
D | SkSLConstantFolder.cpp | 168 static bool is_constant_value(const Expression& expr, double value) { in is_constant_value() function 238 if (is_constant_value(right, 0.0)) { // x + 0 in simplify_no_op_arithmetic() 241 if (is_constant_value(left, 0.0)) { // 0 + x in simplify_no_op_arithmetic() 247 if (is_constant_value(right, 1.0)) { // x * 1 in simplify_no_op_arithmetic() 250 if (is_constant_value(left, 1.0)) { // 1 * x in simplify_no_op_arithmetic() 253 if (is_constant_value(right, 0.0) && !left.hasSideEffects()) { // x * 0 in simplify_no_op_arithmetic() 256 if (is_constant_value(left, 0.0) && !right.hasSideEffects()) { // 0 * x in simplify_no_op_arithmetic() 262 if (is_constant_value(right, 0.0)) { // x - 0 in simplify_no_op_arithmetic() 265 if (is_constant_value(left, 0.0)) { // 0 - x (to `-x`) in simplify_no_op_arithmetic() 273 if (is_constant_value(right, 1.0)) { // x / 1 in simplify_no_op_arithmetic() [all …]
|
/third_party/mesa3d/src/gallium/drivers/vc4/ |
D | vc4_opt_algebraic.c | 63 is_constant_value(struct vc4_compile *c, struct qreg reg, in is_constant_value() function 83 return is_constant_value(c, reg, 0); in is_zero() 90 return is_constant_value(c, reg, fui(1.0)); in is_1f() 255 if (is_constant_value(c, inst->src[0], ~0)) { in qir_opt_algebraic() 260 if (is_constant_value(c, inst->src[1], ~0)) { in qir_opt_algebraic()
|