Lines Matching refs:result

318 static inline zend_result ct_eval_binary_op(zval *result, uint8_t binop, zval *op1, zval *op2) {  in ct_eval_binary_op()  argument
324 return zend_optimizer_eval_binary_op(result, binop, op1, op2); in ct_eval_binary_op()
327 static inline zend_result ct_eval_bool_cast(zval *result, zval *op) { in ct_eval_bool_cast() argument
335 ZVAL_TRUE(result); in ct_eval_bool_cast()
339 ZVAL_BOOL(result, zend_is_true(op)); in ct_eval_bool_cast()
343 static inline zend_result zval_to_string_offset(zend_long *result, zval *op) { in zval_to_string_offset() argument
346 *result = Z_LVAL_P(op); in zval_to_string_offset()
350 Z_STRVAL_P(op), Z_STRLEN_P(op), result, NULL, 0)) { in zval_to_string_offset()
359 static inline zend_result fetch_array_elem(zval **result, zval *op1, zval *op2) { in fetch_array_elem() argument
362 *result = zend_hash_find(Z_ARR_P(op1), ZSTR_EMPTY_ALLOC()); in fetch_array_elem()
365 *result = zend_hash_index_find(Z_ARR_P(op1), 0); in fetch_array_elem()
368 *result = zend_hash_index_find(Z_ARR_P(op1), 1); in fetch_array_elem()
371 *result = zend_hash_index_find(Z_ARR_P(op1), Z_LVAL_P(op2)); in fetch_array_elem()
378 *result = zend_hash_index_find(Z_ARR_P(op1), lval); in fetch_array_elem()
382 *result = zend_symtable_find(Z_ARR_P(op1), Z_STR_P(op2)); in fetch_array_elem()
389 static inline zend_result ct_eval_fetch_dim(zval *result, zval *op1, zval *op2, int support_strings… in ct_eval_fetch_dim() argument
393 ZVAL_COPY(result, value); in ct_eval_fetch_dim()
402 ZVAL_STR(result, zend_string_init(&Z_STRVAL_P(op1)[index], 1, 0)); in ct_eval_fetch_dim()
410 static inline zend_result ct_eval_isset_isempty(zval *result, uint32_t extended_value, zval *op1) { in ct_eval_isset_isempty() argument
413 ZVAL_BOOL(result, op1 && Z_TYPE_P(op1) != IS_NULL); in ct_eval_isset_isempty()
416 ZVAL_TRUE(result); in ct_eval_isset_isempty()
419 ZVAL_BOOL(result, Z_TYPE(zv) == IS_FALSE); in ct_eval_isset_isempty()
426 static inline zend_result ct_eval_isset_dim(zval *result, uint32_t extended_value, zval *op1, zval … in ct_eval_isset_dim() argument
435 return ct_eval_isset_isempty(result, extended_value, value); in ct_eval_isset_dim()
440 ZVAL_BOOL(result, (extended_value & ZEND_ISEMPTY)); in ct_eval_isset_dim()
445 static inline zend_result ct_eval_del_array_elem(zval *result, const zval *key) { in ct_eval_del_array_elem() argument
446 ZEND_ASSERT(IS_PARTIAL_ARRAY(result)); in ct_eval_del_array_elem()
450 zend_hash_del(Z_ARR_P(result), ZSTR_EMPTY_ALLOC()); in ct_eval_del_array_elem()
453 zend_hash_index_del(Z_ARR_P(result), 0); in ct_eval_del_array_elem()
456 zend_hash_index_del(Z_ARR_P(result), 1); in ct_eval_del_array_elem()
459 zend_hash_index_del(Z_ARR_P(result), Z_LVAL_P(key)); in ct_eval_del_array_elem()
466 zend_hash_index_del(Z_ARR_P(result), lval); in ct_eval_del_array_elem()
470 zend_symtable_del(Z_ARR_P(result), Z_STR_P(key)); in ct_eval_del_array_elem()
479 static inline zend_result ct_eval_add_array_elem(zval *result, zval *value, const zval *key) { in ct_eval_add_array_elem() argument
481 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
482 if ((value = zend_hash_next_index_insert(Z_ARR_P(result), value))) { in ct_eval_add_array_elem()
491 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
492 value = zend_hash_update(Z_ARR_P(result), ZSTR_EMPTY_ALLOC(), value); in ct_eval_add_array_elem()
495 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
496 value = zend_hash_index_update(Z_ARR_P(result), 0, value); in ct_eval_add_array_elem()
499 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
500 value = zend_hash_index_update(Z_ARR_P(result), 1, value); in ct_eval_add_array_elem()
503 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
504 value = zend_hash_index_update(Z_ARR_P(result), Z_LVAL_P(key), value); in ct_eval_add_array_elem()
511 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
513 Z_ARR_P(result), lval, value); in ct_eval_add_array_elem()
517 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
518 value = zend_symtable_update(Z_ARR_P(result), Z_STR_P(key), value); in ct_eval_add_array_elem()
528 static inline zend_result ct_eval_add_array_unpack(zval *result, zval *array) { in ct_eval_add_array_unpack() argument
535 SEPARATE_ARRAY(result); in ct_eval_add_array_unpack()
538 value = zend_hash_update(Z_ARR_P(result), key, value); in ct_eval_add_array_unpack()
540 value = zend_hash_next_index_insert(Z_ARR_P(result), value); in ct_eval_add_array_unpack()
550 static inline zend_result ct_eval_assign_dim(zval *result, zval *value, const zval *key) { in ct_eval_assign_dim() argument
551 switch (Z_TYPE_P(result)) { in ct_eval_assign_dim()
554 array_init(result); in ct_eval_assign_dim()
558 return ct_eval_add_array_elem(result, value, key); in ct_eval_assign_dim()
569 if (index >= Z_STRLEN_P(result)) { in ct_eval_assign_dim()
571 memcpy(ZSTR_VAL(new_str), Z_STRVAL_P(result), Z_STRLEN_P(result)); in ct_eval_assign_dim()
572 memset(ZSTR_VAL(new_str) + Z_STRLEN_P(result), ' ', index - Z_STRLEN_P(result)); in ct_eval_assign_dim()
575 new_str = zend_string_init(Z_STRVAL_P(result), Z_STRLEN_P(result), 0); in ct_eval_assign_dim()
579 ZVAL_STR(result, new_str); in ct_eval_assign_dim()
580 Z_STRVAL_P(result)[index] = ZSTR_VAL(value_str)[0]; in ct_eval_assign_dim()
589 static inline zend_result fetch_obj_prop(zval **result, zval *op1, zval *op2) { in fetch_obj_prop() argument
592 *result = zend_symtable_find(Z_ARR_P(op1), Z_STR_P(op2)); in fetch_obj_prop()
599 static inline zend_result ct_eval_fetch_obj(zval *result, zval *op1, zval *op2) { in ct_eval_fetch_obj() argument
603 ZVAL_COPY(result, value); in ct_eval_fetch_obj()
610 static inline zend_result ct_eval_isset_obj(zval *result, uint32_t extended_value, zval *op1, zval … in ct_eval_isset_obj() argument
619 return ct_eval_isset_isempty(result, extended_value, value); in ct_eval_isset_obj()
621 ZVAL_BOOL(result, (extended_value & ZEND_ISEMPTY)); in ct_eval_isset_obj()
626 static inline zend_result ct_eval_del_obj_prop(zval *result, const zval *key) { in ct_eval_del_obj_prop() argument
627 ZEND_ASSERT(IS_PARTIAL_OBJECT(result)); in ct_eval_del_obj_prop()
631 zend_symtable_del(Z_ARR_P(result), Z_STR_P(key)); in ct_eval_del_obj_prop()
640 static inline zend_result ct_eval_add_obj_prop(zval *result, zval *value, const zval *key) { in ct_eval_add_obj_prop() argument
643 value = zend_symtable_update(Z_ARR_P(result), Z_STR_P(key), value); in ct_eval_add_obj_prop()
653 static inline zend_result ct_eval_assign_obj(zval *result, zval *value, const zval *key) { in ct_eval_assign_obj() argument
654 switch (Z_TYPE_P(result)) { in ct_eval_assign_obj()
657 empty_partial_object(result); in ct_eval_assign_obj()
660 return ct_eval_add_obj_prop(result, value, key); in ct_eval_assign_obj()
666 static inline zend_result ct_eval_incdec(zval *result, uint8_t opcode, zval *op1) { in ct_eval_incdec() argument
676 ZVAL_COPY(result, op1); in ct_eval_incdec()
681 increment_function(result); in ct_eval_incdec()
685 zval_ptr_dtor(result); in ct_eval_incdec()
688 decrement_function(result); in ct_eval_incdec()
693 static inline void ct_eval_type_check(zval *result, uint32_t type_mask, zval *op1) { in ct_eval_type_check() argument
700 ZVAL_BOOL(result, (type_mask >> type) & 1); in ct_eval_type_check()
703 static inline zend_result ct_eval_in_array(zval *result, uint32_t extended_value, zval *op1, zval *… in ct_eval_in_array() argument
734 ZVAL_BOOL(result, res); in ct_eval_in_array()
738 static inline zend_result ct_eval_array_key_exists(zval *result, zval *op1, zval *op2) { in ct_eval_array_key_exists() argument
754 ZVAL_BOOL(result, value != NULL); in ct_eval_array_key_exists()
793 zend_op_array *op_array, zval *result, zend_function *func, uint32_t num_args, zval **args) { in ct_eval_func_call_ex() argument
797 zend_optimizer_eval_special_func_call(result, name, Z_STR_P(args[0])) == SUCCESS) { in ct_eval_func_call_ex()
830 ZVAL_NULL(result); in ct_eval_func_call_ex()
831 func->internal_function.handler(execute_data, result); in ct_eval_func_call_ex()
838 zval_ptr_dtor(result); in ct_eval_func_call_ex()
844 zval_ptr_dtor(result); in ct_eval_func_call_ex()
855 zend_op_array *op_array, zval *result, zend_string *name, uint32_t num_args, zval **args) { in ct_eval_func_call() argument
860 return ct_eval_func_call_ex(op_array, result, func, num_args, args); in ct_eval_func_call()
887 SET_RESULT_BOT(result); in sccp_visit_instr()
890 SET_RESULT(result, op2); in sccp_visit_instr()
903 SET_RESULT_BOT(result); in sccp_visit_instr()
916 SET_RESULT_BOT(result); in sccp_visit_instr()
929 SET_RESULT_BOT(result); in sccp_visit_instr()
966 SET_RESULT(result, data); in sccp_visit_instr()
973 SET_RESULT(result, data); in sccp_visit_instr()
976 SET_RESULT_BOT(result); in sccp_visit_instr()
996 SET_RESULT_BOT(result); in sccp_visit_instr()
1002 SET_RESULT_BOT(result); in sccp_visit_instr()
1013 SET_RESULT_BOT(result); in sccp_visit_instr()
1021 SET_RESULT_BOT(result); in sccp_visit_instr()
1051 SET_RESULT(result, data); in sccp_visit_instr()
1054 SET_RESULT_BOT(result); in sccp_visit_instr()
1061 SET_RESULT_BOT(result); in sccp_visit_instr()
1089 zval *result = NULL; in sccp_visit_instr() local
1092 result = &ctx->values[ssa_op->result_use]; in sccp_visit_instr()
1093 if (IS_BOT(result)) { in sccp_visit_instr()
1094 SET_RESULT_BOT(result); in sccp_visit_instr()
1098 SKIP_IF_TOP(result); in sccp_visit_instr()
1112 if (result && Z_TYPE_P(result) == IS_NULL) { in sccp_visit_instr()
1113 SET_RESULT_BOT(result); in sccp_visit_instr()
1122 SET_RESULT(result, &zv); in sccp_visit_instr()
1125 SET_RESULT_BOT(result); in sccp_visit_instr()
1135 if (!result) { in sccp_visit_instr()
1138 MAKE_PARTIAL_ARRAY(result); in sccp_visit_instr()
1139 ZVAL_COPY_VALUE(&zv, result); in sccp_visit_instr()
1140 ZVAL_NULL(result); in sccp_visit_instr()
1144 SET_RESULT(result, &zv); in sccp_visit_instr()
1146 SET_RESULT(result, &zv); in sccp_visit_instr()
1148 SET_RESULT_BOT(result); in sccp_visit_instr()
1154 SET_RESULT_BOT(result); in sccp_visit_instr()
1158 if (result) { in sccp_visit_instr()
1159 ZVAL_COPY_VALUE(&zv, result); in sccp_visit_instr()
1160 ZVAL_NULL(result); in sccp_visit_instr()
1168 SET_RESULT(result, &zv); in sccp_visit_instr()
1173 SET_RESULT(result, &zv); in sccp_visit_instr()
1175 SET_RESULT_BOT(result); in sccp_visit_instr()
1178 SET_RESULT(result, &zv); in sccp_visit_instr()
1186 zval *result = &ctx->values[ssa_op->result_use]; in sccp_visit_instr() local
1187 if (IS_BOT(result) || IS_BOT(op1)) { in sccp_visit_instr()
1188 SET_RESULT_BOT(result); in sccp_visit_instr()
1191 SKIP_IF_TOP(result); in sccp_visit_instr()
1195 if (Z_TYPE_P(result) == IS_NULL) { in sccp_visit_instr()
1196 SET_RESULT_BOT(result); in sccp_visit_instr()
1199 ZVAL_COPY_VALUE(&zv, result); in sccp_visit_instr()
1200 ZVAL_NULL(result); in sccp_visit_instr()
1203 SET_RESULT(result, &zv); in sccp_visit_instr()
1205 SET_RESULT_BOT(result); in sccp_visit_instr()
1214 SET_RESULT(result, &zv); in sccp_visit_instr()
1217 SET_RESULT_BOT(result); in sccp_visit_instr()
1224 SET_RESULT_BOT(result); in sccp_visit_instr()
1236 SET_RESULT_BOT(result); in sccp_visit_instr()
1269 SET_RESULT(result, &zv); in sccp_visit_instr()
1273 SET_RESULT_BOT(result); in sccp_visit_instr()
1288 SET_RESULT(result, &zv); in sccp_visit_instr()
1304 SET_RESULT_BOT(result); in sccp_visit_instr()
1312 SET_RESULT_BOT(result); in sccp_visit_instr()
1325 SET_RESULT(result, &tmp); in sccp_visit_instr()
1349 SET_RESULT_BOT(result); in sccp_visit_instr()
1357 SET_RESULT_BOT(result); in sccp_visit_instr()
1366 SET_RESULT(result, &tmp); in sccp_visit_instr()
1378 SET_RESULT_BOT(result); in sccp_visit_instr()
1398 SET_RESULT(result, &tmp2); in sccp_visit_instr()
1400 SET_RESULT(result, &tmp1); in sccp_visit_instr()
1413 SET_RESULT_BOT(result); in sccp_visit_instr()
1420 SET_RESULT(result, &zv); in sccp_visit_instr()
1425 SET_RESULT_BOT(result); in sccp_visit_instr()
1430 SET_RESULT(result, op1); in sccp_visit_instr()
1442 SET_RESULT_BOT(result); in sccp_visit_instr()
1446 SET_RESULT(result, &zv); in sccp_visit_instr()
1450 SET_RESULT_BOT(result); in sccp_visit_instr()
1455 SET_RESULT_BOT(result); in sccp_visit_instr()
1459 SET_RESULT(result, &zv); in sccp_visit_instr()
1463 SET_RESULT_BOT(result); in sccp_visit_instr()
1470 SET_RESULT(result, &zv); in sccp_visit_instr()
1474 SET_RESULT_BOT(result); in sccp_visit_instr()
1479 SET_RESULT(result, &zv); in sccp_visit_instr()
1483 SET_RESULT_BOT(result); in sccp_visit_instr()
1490 SET_RESULT(result, &zv); in sccp_visit_instr()
1493 SET_RESULT_BOT(result); in sccp_visit_instr()
1499 SET_RESULT(result, &zv); in sccp_visit_instr()
1503 SET_RESULT_BOT(result); in sccp_visit_instr()
1509 SET_RESULT(result, &zv); in sccp_visit_instr()
1513 SET_RESULT_BOT(result); in sccp_visit_instr()
1519 SET_RESULT(result, &zv); in sccp_visit_instr()
1523 SET_RESULT_BOT(result); in sccp_visit_instr()
1532 SET_RESULT(result, &zv); in sccp_visit_instr()
1536 SET_RESULT_BOT(result); in sccp_visit_instr()
1543 SET_RESULT(result, &zv); in sccp_visit_instr()
1547 SET_RESULT_BOT(result); in sccp_visit_instr()
1556 SET_RESULT(result, &zv); in sccp_visit_instr()
1561 SET_RESULT_BOT(result); in sccp_visit_instr()
1569 SET_RESULT(result, &zv); in sccp_visit_instr()
1574 SET_RESULT_BOT(result); in sccp_visit_instr()
1580 SET_RESULT(result, op1); in sccp_visit_instr()
1595 SET_RESULT(result, &zv); in sccp_visit_instr()
1598 SET_RESULT(result, op2); in sccp_visit_instr()
1603 SET_RESULT(result, &zv); in sccp_visit_instr()
1607 SET_RESULT_BOT(result); in sccp_visit_instr()
1612 SET_RESULT(result, &zv); in sccp_visit_instr()
1618 SET_RESULT(result, &zv); in sccp_visit_instr()
1623 SET_RESULT_BOT(result); in sccp_visit_instr()
1627 SET_RESULT(result, &zv); in sccp_visit_instr()
1631 SET_RESULT_BOT(result); in sccp_visit_instr()
1641 SET_RESULT(result, &zv); in sccp_visit_instr()
1645 SET_RESULT_BOT(result); in sccp_visit_instr()
1654 SET_RESULT_BOT(result); in sccp_visit_instr()
1669 SET_RESULT_BOT(result); in sccp_visit_instr()
1676 SET_RESULT_BOT(result); in sccp_visit_instr()
1684 SET_RESULT_BOT(result); in sccp_visit_instr()
1698 SET_RESULT(result, &zv); in sccp_visit_instr()
1713 SET_RESULT_BOT(result); in sccp_visit_instr()
1744 SET_RESULT_BOT(result); in sccp_visit_instr()
1747 SET_RESULT_BOT(result); in sccp_visit_instr()
1754 SET_RESULT(result, &zv); in sccp_visit_instr()
1758 SET_RESULT_BOT(result); in sccp_visit_instr()
1764 SET_RESULT_BOT(result); in sccp_visit_instr()
2048 zval result; in sccp_visit_phi() local
2049 MAKE_TOP(&result); in sccp_visit_phi()
2056 …join_phi_values(&result, &ctx->values[phi->sources[0]], ssa->vars[phi->ssa_var].escape_state != ES… in sccp_visit_phi()
2066 …join_phi_values(&result, &ctx->values[phi->sources[i]], ssa->vars[phi->ssa_var].escape_state != ES… in sccp_visit_phi()
2078 set_value(scdf, ctx, phi->ssa_var, &result); in sccp_visit_phi()
2079 zval_ptr_dtor_nogc(&result); in sccp_visit_phi()
2202 uint32_t old_var = opline->result.var; in try_remove_definition()
2219 opline->result.var = old_var; in try_remove_definition()