Lines Matching refs:result
368 static inline int ct_eval_binary_op(zval *result, zend_uchar binop, zval *op1, zval *op2) { in ct_eval_binary_op() argument
374 return zend_optimizer_eval_binary_op(result, binop, op1, op2); in ct_eval_binary_op()
377 static inline int ct_eval_bool_cast(zval *result, zval *op) { in ct_eval_bool_cast() argument
385 ZVAL_TRUE(result); in ct_eval_bool_cast()
389 ZVAL_BOOL(result, zend_is_true(op)); in ct_eval_bool_cast()
393 static inline int zval_to_string_offset(zend_long *result, zval *op) { in zval_to_string_offset() argument
396 *result = Z_LVAL_P(op); in zval_to_string_offset()
400 Z_STRVAL_P(op), Z_STRLEN_P(op), result, NULL, 0)) { in zval_to_string_offset()
409 static inline int fetch_array_elem(zval **result, zval *op1, zval *op2) { in fetch_array_elem() argument
412 *result = zend_hash_find(Z_ARR_P(op1), ZSTR_EMPTY_ALLOC()); in fetch_array_elem()
415 *result = zend_hash_index_find(Z_ARR_P(op1), 0); in fetch_array_elem()
418 *result = zend_hash_index_find(Z_ARR_P(op1), 1); in fetch_array_elem()
421 *result = zend_hash_index_find(Z_ARR_P(op1), Z_LVAL_P(op2)); in fetch_array_elem()
424 *result = zend_hash_index_find(Z_ARR_P(op1), zend_dval_to_lval(Z_DVAL_P(op2))); in fetch_array_elem()
427 *result = zend_symtable_find(Z_ARR_P(op1), Z_STR_P(op2)); in fetch_array_elem()
434 static inline int ct_eval_fetch_dim(zval *result, zval *op1, zval *op2, int support_strings) { in ct_eval_fetch_dim() argument
438 ZVAL_COPY(result, value); in ct_eval_fetch_dim()
447 ZVAL_STR(result, zend_string_init(&Z_STRVAL_P(op1)[index], 1, 0)); in ct_eval_fetch_dim()
455 static inline int ct_eval_isset_isempty(zval *result, uint32_t extended_value, zval *op1) { in ct_eval_isset_isempty() argument
458 ZVAL_BOOL(result, op1 && Z_TYPE_P(op1) != IS_NULL); in ct_eval_isset_isempty()
461 ZVAL_TRUE(result); in ct_eval_isset_isempty()
464 ZVAL_BOOL(result, Z_TYPE(zv) == IS_FALSE); in ct_eval_isset_isempty()
471 static inline int ct_eval_isset_dim(zval *result, uint32_t extended_value, zval *op1, zval *op2) { in ct_eval_isset_dim() argument
480 return ct_eval_isset_isempty(result, extended_value, value); in ct_eval_isset_dim()
485 ZVAL_BOOL(result, (extended_value & ZEND_ISEMPTY)); in ct_eval_isset_dim()
490 static inline int ct_eval_del_array_elem(zval *result, zval *key) { in ct_eval_del_array_elem() argument
491 ZEND_ASSERT(IS_PARTIAL_ARRAY(result)); in ct_eval_del_array_elem()
495 zend_hash_del(Z_ARR_P(result), ZSTR_EMPTY_ALLOC()); in ct_eval_del_array_elem()
498 zend_hash_index_del(Z_ARR_P(result), 0); in ct_eval_del_array_elem()
501 zend_hash_index_del(Z_ARR_P(result), 1); in ct_eval_del_array_elem()
504 zend_hash_index_del(Z_ARR_P(result), Z_LVAL_P(key)); in ct_eval_del_array_elem()
507 zend_hash_index_del(Z_ARR_P(result), zend_dval_to_lval(Z_DVAL_P(key))); in ct_eval_del_array_elem()
510 zend_symtable_del(Z_ARR_P(result), Z_STR_P(key)); in ct_eval_del_array_elem()
519 static inline int ct_eval_add_array_elem(zval *result, zval *value, zval *key) { in ct_eval_add_array_elem() argument
521 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
522 if ((value = zend_hash_next_index_insert(Z_ARR_P(result), value))) { in ct_eval_add_array_elem()
531 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
532 value = zend_hash_update(Z_ARR_P(result), ZSTR_EMPTY_ALLOC(), value); in ct_eval_add_array_elem()
535 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
536 value = zend_hash_index_update(Z_ARR_P(result), 0, value); in ct_eval_add_array_elem()
539 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
540 value = zend_hash_index_update(Z_ARR_P(result), 1, value); in ct_eval_add_array_elem()
543 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
544 value = zend_hash_index_update(Z_ARR_P(result), Z_LVAL_P(key), value); in ct_eval_add_array_elem()
547 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
549 Z_ARR_P(result), zend_dval_to_lval(Z_DVAL_P(key)), value); in ct_eval_add_array_elem()
552 SEPARATE_ARRAY(result); in ct_eval_add_array_elem()
553 value = zend_symtable_update(Z_ARR_P(result), Z_STR_P(key), value); in ct_eval_add_array_elem()
563 static inline int ct_eval_add_array_unpack(zval *result, zval *array) { in ct_eval_add_array_unpack() argument
570 SEPARATE_ARRAY(result); in ct_eval_add_array_unpack()
575 value = zend_hash_next_index_insert(Z_ARR_P(result), value); in ct_eval_add_array_unpack()
584 static inline int ct_eval_assign_dim(zval *result, zval *value, zval *key) { in ct_eval_assign_dim() argument
585 switch (Z_TYPE_P(result)) { in ct_eval_assign_dim()
588 array_init(result); in ct_eval_assign_dim()
592 return ct_eval_add_array_elem(result, value, key); in ct_eval_assign_dim()
603 if (index >= Z_STRLEN_P(result)) { in ct_eval_assign_dim()
605 memcpy(ZSTR_VAL(new_str), Z_STRVAL_P(result), Z_STRLEN_P(result)); in ct_eval_assign_dim()
606 memset(ZSTR_VAL(new_str) + Z_STRLEN_P(result), ' ', index - Z_STRLEN_P(result)); in ct_eval_assign_dim()
609 new_str = zend_string_init(Z_STRVAL_P(result), Z_STRLEN_P(result), 0); in ct_eval_assign_dim()
613 ZVAL_STR(result, new_str); in ct_eval_assign_dim()
614 Z_STRVAL_P(result)[index] = ZSTR_VAL(value_str)[0]; in ct_eval_assign_dim()
623 static inline int fetch_obj_prop(zval **result, zval *op1, zval *op2) { in fetch_obj_prop() argument
626 *result = zend_symtable_find(Z_ARR_P(op1), Z_STR_P(op2)); in fetch_obj_prop()
633 static inline int ct_eval_fetch_obj(zval *result, zval *op1, zval *op2) { in ct_eval_fetch_obj() argument
637 ZVAL_COPY(result, value); in ct_eval_fetch_obj()
644 static inline int ct_eval_isset_obj(zval *result, uint32_t extended_value, zval *op1, zval *op2) { in ct_eval_isset_obj() argument
653 return ct_eval_isset_isempty(result, extended_value, value); in ct_eval_isset_obj()
655 ZVAL_BOOL(result, (extended_value & ZEND_ISEMPTY)); in ct_eval_isset_obj()
660 static inline int ct_eval_del_obj_prop(zval *result, zval *key) { in ct_eval_del_obj_prop() argument
661 ZEND_ASSERT(IS_PARTIAL_OBJECT(result)); in ct_eval_del_obj_prop()
665 zend_symtable_del(Z_ARR_P(result), Z_STR_P(key)); in ct_eval_del_obj_prop()
674 static inline int ct_eval_add_obj_prop(zval *result, zval *value, zval *key) { in ct_eval_add_obj_prop() argument
677 value = zend_symtable_update(Z_ARR_P(result), Z_STR_P(key), value); in ct_eval_add_obj_prop()
687 static inline int ct_eval_assign_obj(zval *result, zval *value, zval *key) { in ct_eval_assign_obj() argument
688 switch (Z_TYPE_P(result)) { in ct_eval_assign_obj()
691 empty_partial_object(result); in ct_eval_assign_obj()
694 return ct_eval_add_obj_prop(result, value, key); in ct_eval_assign_obj()
700 static inline int ct_eval_incdec(zval *result, zend_uchar opcode, zval *op1) { in ct_eval_incdec() argument
701 ZVAL_COPY(result, op1); in ct_eval_incdec()
706 increment_function(result); in ct_eval_incdec()
708 decrement_function(result); in ct_eval_incdec()
713 static inline void ct_eval_type_check(zval *result, uint32_t type_mask, zval *op1) { in ct_eval_type_check() argument
720 ZVAL_BOOL(result, (type_mask >> type) & 1); in ct_eval_type_check()
723 static inline int ct_eval_in_array(zval *result, uint32_t extended_value, zval *op1, zval *op2) { in ct_eval_in_array() argument
755 ZVAL_BOOL(result, res); in ct_eval_in_array()
759 static inline int ct_eval_array_key_exists(zval *result, zval *op1, zval *op2) { in ct_eval_array_key_exists() argument
775 ZVAL_BOOL(result, value != NULL); in ct_eval_array_key_exists()
783 zval *result, zend_string *name, uint32_t num_args, zval **args) { in ct_eval_func_call() argument
807 ZVAL_INTERNED_STR(result, ZSTR_CHAR(c)); in ct_eval_func_call()
814 ZVAL_LONG(result, zend_hash_num_elements(Z_ARRVAL_P(args[0]))); in ct_eval_func_call()
825 ZVAL_FALSE(result); in ct_eval_func_call()
829 ZVAL_STR_COPY(result, ini_entry->value); in ct_eval_func_call()
831 ZVAL_EMPTY_STRING(result); in ct_eval_func_call()
1048 func->internal_function.handler(execute_data, result); in ct_eval_func_call()
1084 SET_RESULT(result, op2); in sccp_visit_instr()
1094 SET_RESULT(result, &zv); in sccp_visit_instr()
1099 SET_RESULT(result, &zv); in sccp_visit_instr()
1114 SET_RESULT_BOT(result); in sccp_visit_instr()
1127 SET_RESULT_BOT(result); in sccp_visit_instr()
1140 SET_RESULT_BOT(result); in sccp_visit_instr()
1177 SET_RESULT(result, data); in sccp_visit_instr()
1184 SET_RESULT(result, data); in sccp_visit_instr()
1187 SET_RESULT_BOT(result); in sccp_visit_instr()
1205 SET_RESULT_BOT(result); in sccp_visit_instr()
1216 SET_RESULT_BOT(result); in sccp_visit_instr()
1227 SET_RESULT_BOT(result); in sccp_visit_instr()
1235 SET_RESULT_BOT(result); in sccp_visit_instr()
1265 SET_RESULT(result, data); in sccp_visit_instr()
1268 SET_RESULT_BOT(result); in sccp_visit_instr()
1275 SET_RESULT_BOT(result); in sccp_visit_instr()
1303 zval *result = NULL; in sccp_visit_instr() local
1306 result = &ctx->values[ssa_op->result_use]; in sccp_visit_instr()
1307 if (IS_BOT(result)) { in sccp_visit_instr()
1308 SET_RESULT_BOT(result); in sccp_visit_instr()
1312 SKIP_IF_TOP(result); in sccp_visit_instr()
1326 if (result && Z_TYPE_P(result) == IS_NULL) { in sccp_visit_instr()
1327 SET_RESULT_BOT(result); in sccp_visit_instr()
1336 SET_RESULT(result, &zv); in sccp_visit_instr()
1339 SET_RESULT_BOT(result); in sccp_visit_instr()
1349 if (!result) { in sccp_visit_instr()
1352 MAKE_PARTIAL_ARRAY(result); in sccp_visit_instr()
1353 ZVAL_COPY_VALUE(&zv, result); in sccp_visit_instr()
1354 ZVAL_NULL(result); in sccp_visit_instr()
1358 SET_RESULT(result, &zv); in sccp_visit_instr()
1360 SET_RESULT(result, &zv); in sccp_visit_instr()
1362 SET_RESULT_BOT(result); in sccp_visit_instr()
1368 SET_RESULT_BOT(result); in sccp_visit_instr()
1372 if (result) { in sccp_visit_instr()
1373 ZVAL_COPY_VALUE(&zv, result); in sccp_visit_instr()
1374 ZVAL_NULL(result); in sccp_visit_instr()
1382 SET_RESULT(result, &zv); in sccp_visit_instr()
1387 SET_RESULT(result, &zv); in sccp_visit_instr()
1389 SET_RESULT_BOT(result); in sccp_visit_instr()
1392 SET_RESULT(result, &zv); in sccp_visit_instr()
1400 zval *result = &ctx->values[ssa_op->result_use]; in sccp_visit_instr() local
1401 if (IS_BOT(result) || IS_BOT(op1)) { in sccp_visit_instr()
1402 SET_RESULT_BOT(result); in sccp_visit_instr()
1405 SKIP_IF_TOP(result); in sccp_visit_instr()
1409 if (Z_TYPE_P(result) == IS_NULL) { in sccp_visit_instr()
1410 SET_RESULT_BOT(result); in sccp_visit_instr()
1413 ZVAL_COPY_VALUE(&zv, result); in sccp_visit_instr()
1414 ZVAL_NULL(result); in sccp_visit_instr()
1417 SET_RESULT(result, &zv); in sccp_visit_instr()
1419 SET_RESULT_BOT(result); in sccp_visit_instr()
1428 SET_RESULT(result, &zv); in sccp_visit_instr()
1431 SET_RESULT_BOT(result); in sccp_visit_instr()
1438 SET_RESULT_BOT(result); in sccp_visit_instr()
1450 SET_RESULT_BOT(result); in sccp_visit_instr()
1482 SET_RESULT(result, &zv); in sccp_visit_instr()
1486 SET_RESULT_BOT(result); in sccp_visit_instr()
1501 SET_RESULT(result, &zv); in sccp_visit_instr()
1517 SET_RESULT_BOT(result); in sccp_visit_instr()
1525 SET_RESULT_BOT(result); in sccp_visit_instr()
1538 SET_RESULT(result, &tmp); in sccp_visit_instr()
1562 SET_RESULT_BOT(result); in sccp_visit_instr()
1570 SET_RESULT_BOT(result); in sccp_visit_instr()
1579 SET_RESULT(result, &tmp); in sccp_visit_instr()
1591 SET_RESULT_BOT(result); in sccp_visit_instr()
1613 SET_RESULT(result, &tmp2); in sccp_visit_instr()
1615 SET_RESULT(result, &tmp1); in sccp_visit_instr()
1624 SET_RESULT_BOT(result); in sccp_visit_instr()
1631 SET_RESULT(result, &zv); in sccp_visit_instr()
1636 SET_RESULT_BOT(result); in sccp_visit_instr()
1641 SET_RESULT(result, op1); in sccp_visit_instr()
1653 SET_RESULT_BOT(result); in sccp_visit_instr()
1657 SET_RESULT(result, &zv); in sccp_visit_instr()
1661 SET_RESULT_BOT(result); in sccp_visit_instr()
1666 SET_RESULT_BOT(result); in sccp_visit_instr()
1670 SET_RESULT(result, &zv); in sccp_visit_instr()
1674 SET_RESULT_BOT(result); in sccp_visit_instr()
1681 SET_RESULT(result, &zv); in sccp_visit_instr()
1685 SET_RESULT_BOT(result); in sccp_visit_instr()
1690 SET_RESULT(result, &zv); in sccp_visit_instr()
1694 SET_RESULT_BOT(result); in sccp_visit_instr()
1700 SET_RESULT(result, &zv); in sccp_visit_instr()
1704 SET_RESULT_BOT(result); in sccp_visit_instr()
1710 SET_RESULT(result, &zv); in sccp_visit_instr()
1714 SET_RESULT_BOT(result); in sccp_visit_instr()
1720 SET_RESULT(result, &zv); in sccp_visit_instr()
1724 SET_RESULT_BOT(result); in sccp_visit_instr()
1733 SET_RESULT(result, &zv); in sccp_visit_instr()
1737 SET_RESULT_BOT(result); in sccp_visit_instr()
1744 SET_RESULT(result, &zv); in sccp_visit_instr()
1748 SET_RESULT_BOT(result); in sccp_visit_instr()
1757 SET_RESULT(result, &zv); in sccp_visit_instr()
1762 SET_RESULT_BOT(result); in sccp_visit_instr()
1770 SET_RESULT(result, &zv); in sccp_visit_instr()
1775 SET_RESULT_BOT(result); in sccp_visit_instr()
1781 SET_RESULT(result, op1); in sccp_visit_instr()
1786 SET_RESULT_BOT(result); in sccp_visit_instr()
1789 SET_RESULT(result, op1); in sccp_visit_instr()
1795 SET_RESULT(result, &zv); in sccp_visit_instr()
1799 SET_RESULT_BOT(result); in sccp_visit_instr()
1804 SET_RESULT(result, &zv); in sccp_visit_instr()
1810 SET_RESULT(result, &zv); in sccp_visit_instr()
1815 SET_RESULT_BOT(result); in sccp_visit_instr()
1819 SET_RESULT(result, &zv); in sccp_visit_instr()
1823 SET_RESULT_BOT(result); in sccp_visit_instr()
1833 SET_RESULT(result, &zv); in sccp_visit_instr()
1837 SET_RESULT_BOT(result); in sccp_visit_instr()
1846 SET_RESULT_BOT(result); in sccp_visit_instr()
1860 SET_RESULT_BOT(result); in sccp_visit_instr()
1867 SET_RESULT_BOT(result); in sccp_visit_instr()
1875 SET_RESULT_BOT(result); in sccp_visit_instr()
1889 SET_RESULT(result, &zv); in sccp_visit_instr()
1904 SET_RESULT_BOT(result); in sccp_visit_instr()
1910 SET_RESULT_BOT(result); in sccp_visit_instr()
2135 zval result; in sccp_visit_phi() local
2136 MAKE_TOP(&result); in sccp_visit_phi()
2143 …join_phi_values(&result, &ctx->values[phi->sources[0]], ssa->vars[phi->ssa_var].escape_state != ES… in sccp_visit_phi()
2153 …join_phi_values(&result, &ctx->values[phi->sources[i]], ssa->vars[phi->ssa_var].escape_state != ES… in sccp_visit_phi()
2165 set_value(scdf, ctx, phi->ssa_var, &result); in sccp_visit_phi()
2166 zval_ptr_dtor_nogc(&result); in sccp_visit_phi()
2293 uint32_t old_var = opline->result.var; in try_remove_definition()
2304 opline->result.var = old_var; in try_remove_definition()