Lines Matching refs:ssa_var
378 int ssa_var, in zend_jit_trace_add_op_guard() argument
381 zend_ssa_var_info *info = &tssa->var_info[ssa_var]; in zend_jit_trace_add_op_guard()
384 if (UNEXPECTED(tssa->vars[ssa_var].alias != NO_ALIAS)) { in zend_jit_trace_add_op_guard()
711 phi->ssa_var = ssa_vars_count; in zend_jit_trace_add_phis()
748 phi->ssa_var = ssa_vars_count; in zend_jit_trace_add_call_phis()
780 phi->ssa_var = ssa_vars_count; in zend_jit_trace_add_ret_phis()
812 int ssa_var, in zend_jit_trace_copy_ssa_var_info() argument
818 if (tssa->vars[ssa_var].definition_phi) { in zend_jit_trace_copy_ssa_var_info()
827 var = tssa->vars[ssa_var].var; in zend_jit_trace_copy_ssa_var_info()
829 if (ssa->vars[phi->ssa_var].var == var) { in zend_jit_trace_copy_ssa_var_info()
833 src = phi->ssa_var; in zend_jit_trace_copy_ssa_var_info()
840 src = pi->ssa_var; in zend_jit_trace_copy_ssa_var_info()
867 if (ssa->vars[phi->ssa_var].var == var) { in zend_jit_trace_copy_ssa_var_info()
871 src = phi->ssa_var; in zend_jit_trace_copy_ssa_var_info()
878 src = pi->ssa_var; in zend_jit_trace_copy_ssa_var_info()
884 } else if (tssa->vars[ssa_var].definition >= 0) { in zend_jit_trace_copy_ssa_var_info()
885 def = tssa->vars[ssa_var].definition; in zend_jit_trace_copy_ssa_var_info()
888 if (tssa->ops[def].op1_def == ssa_var) { in zend_jit_trace_copy_ssa_var_info()
890 } else if (tssa->ops[def].op2_def == ssa_var) { in zend_jit_trace_copy_ssa_var_info()
892 } else if (tssa->ops[def].result_def == ssa_var) { in zend_jit_trace_copy_ssa_var_info()
901 if (tssa->vars[ssa_var].phi_use_chain) { in zend_jit_trace_copy_ssa_var_info()
903 var = tssa->vars[ssa_var].phi_use_chain->ssa_var; in zend_jit_trace_copy_ssa_var_info()
905 var = ssa_var; in zend_jit_trace_copy_ssa_var_info()
923 var = tssa->vars[ssa_var].var; in zend_jit_trace_copy_ssa_var_info()
947 if (ssa->vars[phi->ssa_var].var == var) { in zend_jit_trace_copy_ssa_var_info()
951 src = phi->ssa_var; in zend_jit_trace_copy_ssa_var_info()
958 src = pi->ssa_var; in zend_jit_trace_copy_ssa_var_info()
974 tssa->vars[ssa_var].no_val = ssa->vars[src].no_val; in zend_jit_trace_copy_ssa_var_info()
975 tssa->vars[ssa_var].alias = ssa->vars[src].alias; in zend_jit_trace_copy_ssa_var_info()
976 memcpy(&tssa->var_info[ssa_var], &ssa->var_info[src], sizeof(zend_ssa_var_info)); in zend_jit_trace_copy_ssa_var_info()
980 …ate_range(const zend_op_array *op_array, const zend_op **tssa_opcodes, zend_ssa *tssa, int ssa_var) in zend_jit_trace_propagate_range() argument
983 int def = tssa->vars[ssa_var].definition; in zend_jit_trace_propagate_range()
985 if (tssa->vars[ssa_var].alias == NO_ALIAS in zend_jit_trace_propagate_range()
986 …&& zend_inference_propagate_range(op_array, tssa, tssa_opcodes[def], &tssa->ops[def], ssa_var, &tm… in zend_jit_trace_propagate_range()
987 tssa->var_info[ssa_var].range.min = tmp.min; in zend_jit_trace_propagate_range()
988 tssa->var_info[ssa_var].range.max = tmp.max; in zend_jit_trace_propagate_range()
989 tssa->var_info[ssa_var].range.underflow = tmp.underflow; in zend_jit_trace_propagate_range()
990 tssa->var_info[ssa_var].range.overflow = tmp.overflow; in zend_jit_trace_propagate_range()
991 tssa->var_info[ssa_var].has_range = 1; in zend_jit_trace_propagate_range()
995 …op_array *op_array, const zend_ssa *ssa, const zend_op **tssa_opcodes, zend_ssa *tssa, int ssa_var) in zend_jit_trace_copy_ssa_var_range() argument
1003 def = tssa->vars[ssa_var].definition; in zend_jit_trace_copy_ssa_var_range()
1007 if (tssa->ops[def].op1_def == ssa_var) { in zend_jit_trace_copy_ssa_var_range()
1011 } else if (tssa->ops[def].op2_def == ssa_var) { in zend_jit_trace_copy_ssa_var_range()
1015 } else if (tssa->ops[def].result_def == ssa_var) { in zend_jit_trace_copy_ssa_var_range()
1024 tssa->vars[ssa_var].no_val = no_val; in zend_jit_trace_copy_ssa_var_range()
1025 tssa->vars[ssa_var].alias = alias; in zend_jit_trace_copy_ssa_var_range()
1028 zend_jit_trace_propagate_range(op_array, tssa_opcodes, tssa, ssa_var); in zend_jit_trace_copy_ssa_var_range()
1032 if (tssa->var_info[ssa_var].has_range) { in zend_jit_trace_copy_ssa_var_range()
1033 tssa->var_info[ssa_var].range.min = MAX(tssa->var_info[ssa_var].range.min, info->range.min); in zend_jit_trace_copy_ssa_var_range()
1034 tssa->var_info[ssa_var].range.max = MIN(tssa->var_info[ssa_var].range.max, info->range.max); in zend_jit_trace_copy_ssa_var_range()
1035 …tssa->var_info[ssa_var].range.underflow = tssa->var_info[ssa_var].range.underflow && info->range.u… in zend_jit_trace_copy_ssa_var_range()
1036 …tssa->var_info[ssa_var].range.overflow = tssa->var_info[ssa_var].range.overflow && info->range.ove… in zend_jit_trace_copy_ssa_var_range()
1038 tssa->var_info[ssa_var].has_range = 1; in zend_jit_trace_copy_ssa_var_range()
1039 tssa->var_info[ssa_var].range = info->range; in zend_jit_trace_copy_ssa_var_range()
1045 …op_array *op_array, const zend_ssa *ssa, const zend_op **tssa_opcodes, zend_ssa *tssa, int ssa_var) in zend_jit_trace_restrict_ssa_var_info() argument
1051 def = tssa->vars[ssa_var].definition; in zend_jit_trace_restrict_ssa_var_info()
1055 if (tssa->ops[def].op1_def == ssa_var) { in zend_jit_trace_restrict_ssa_var_info()
1057 } else if (tssa->ops[def].op2_def == ssa_var) { in zend_jit_trace_restrict_ssa_var_info()
1059 } else if (tssa->ops[def].result_def == ssa_var) { in zend_jit_trace_restrict_ssa_var_info()
1065 tssa->var_info[ssa_var].type &= info->type; in zend_jit_trace_restrict_ssa_var_info()
1067 if (tssa->var_info[ssa_var].ce) { in zend_jit_trace_restrict_ssa_var_info()
1068 if (tssa->var_info[ssa_var].ce != info->ce) { in zend_jit_trace_restrict_ssa_var_info()
1069 if (instanceof_function(tssa->var_info[ssa_var].ce, info->ce)) { in zend_jit_trace_restrict_ssa_var_info()
1071 } else if (instanceof_function(info->ce, tssa->var_info[ssa_var].ce)) { in zend_jit_trace_restrict_ssa_var_info()
1078 tssa->var_info[ssa_var].is_instanceof = in zend_jit_trace_restrict_ssa_var_info()
1079 tssa->var_info[ssa_var].is_instanceof && info->is_instanceof; in zend_jit_trace_restrict_ssa_var_info()
1081 tssa->var_info[ssa_var].ce = info->ce; in zend_jit_trace_restrict_ssa_var_info()
1082 tssa->var_info[ssa_var].is_instanceof = info->is_instanceof; in zend_jit_trace_restrict_ssa_var_info()
1086 if (tssa->var_info[ssa_var].has_range) { in zend_jit_trace_restrict_ssa_var_info()
1087 tssa->var_info[ssa_var].range.min = MAX(tssa->var_info[ssa_var].range.min, info->range.min); in zend_jit_trace_restrict_ssa_var_info()
1088 tssa->var_info[ssa_var].range.max = MIN(tssa->var_info[ssa_var].range.max, info->range.max); in zend_jit_trace_restrict_ssa_var_info()
1089 …tssa->var_info[ssa_var].range.underflow = tssa->var_info[ssa_var].range.underflow && info->range.u… in zend_jit_trace_restrict_ssa_var_info()
1090 …tssa->var_info[ssa_var].range.overflow = tssa->var_info[ssa_var].range.overflow && info->range.ove… in zend_jit_trace_restrict_ssa_var_info()
1092 tssa->var_info[ssa_var].has_range = 1; in zend_jit_trace_restrict_ssa_var_info()
1093 tssa->var_info[ssa_var].range = info->range; in zend_jit_trace_restrict_ssa_var_info()
1638 ssa_vars[phi->ssa_var].var = phi->var; in zend_jit_trace_build_tssa()
1639 ssa_vars[phi->ssa_var].definition_phi = phi; in zend_jit_trace_build_tssa()
1786 || !zend_jit_trace_copy_ssa_var_info(op_array, ssa, ssa_opcodes, tssa, phi->ssa_var, NULL)) { in zend_jit_trace_build_tssa()
1787 ssa_vars[phi->ssa_var].alias = ssa_vars[phi->sources[0]].alias; in zend_jit_trace_build_tssa()
1788 ssa_var_info[phi->ssa_var].type = ssa_var_info[phi->sources[0]].type; in zend_jit_trace_build_tssa()
2693 uint32_t t = ssa_var_info[phi->ssa_var].type; in zend_jit_trace_build_tssa()
2695 if ((t & MAY_BE_GUARD) && tssa->vars[phi->ssa_var].alias == NO_ALIAS) { in zend_jit_trace_build_tssa()
2701 ssa_var_info[phi->ssa_var].type = t & ~MAY_BE_GUARD; in zend_jit_trace_build_tssa()
2705 || is_checked_guard(tssa, ssa_opcodes, phi->sources[1], phi->ssa_var)) { in zend_jit_trace_build_tssa()
2706 ssa_var_info[phi->ssa_var].type = t & ~MAY_BE_GUARD; in zend_jit_trace_build_tssa()
2734 && is_checked_guard(tssa, ssa_opcodes, phi->sources[1], phi->ssa_var)) { in zend_jit_trace_build_tssa()
2745 ssa_var_info[phi->ssa_var].type = t & ~MAY_BE_GUARD; in zend_jit_trace_build_tssa()
2749 t = ssa_var_info[phi->ssa_var].type; in zend_jit_trace_build_tssa()
2752 if ((t & MAY_BE_PACKED_GUARD) && tssa->vars[phi->ssa_var].alias == NO_ALIAS) { in zend_jit_trace_build_tssa()
2758 ssa_var_info[phi->ssa_var].type = t & ~MAY_BE_PACKED_GUARD; in zend_jit_trace_build_tssa()
2762 ssa_var_info[phi->ssa_var].type = t & ~MAY_BE_PACKED_GUARD; in zend_jit_trace_build_tssa()
2931 SET_STACK_VAR(stack, phi->var, phi->ssa_var); in zend_jit_trace_allocate_registers()
2932 vars_op_array[phi->ssa_var] = op_array; in zend_jit_trace_allocate_registers()
2933 if (ssa->vars[phi->ssa_var].use_chain >= 0 in zend_jit_trace_allocate_registers()
2934 && ssa->vars[phi->ssa_var].alias == NO_ALIAS in zend_jit_trace_allocate_registers()
2935 && zend_jit_var_supports_reg(ssa, phi->ssa_var)) { in zend_jit_trace_allocate_registers()
2936 RA_IVAL_START(phi->ssa_var, 0); in zend_jit_trace_allocate_registers()
3257 if (RA_HAS_IVAL(i) && !ssa->vars[phi->ssa_var].no_val) { in zend_jit_trace_allocate_registers()
3299 int def = phi->ssa_var; in zend_jit_trace_allocate_registers()
3942 int ssa_var, j, b = ssa->cfg.map[opline_num]; in zend_jit_find_ssa_var() local
3951 ssa_var = ssa_op->result_def; in zend_jit_find_ssa_var()
3952 if (ssa_var >= 0 && ssa->vars[ssa_var].var == var_num) { in zend_jit_find_ssa_var()
3953 return ssa_var; in zend_jit_find_ssa_var()
3955 ssa_var = ssa_op->op2_def; in zend_jit_find_ssa_var()
3956 if (ssa_var >= 0 && ssa->vars[ssa_var].var == var_num) { in zend_jit_find_ssa_var()
3957 return ssa_var; in zend_jit_find_ssa_var()
3959 ssa_var = ssa_op->op1_def; in zend_jit_find_ssa_var()
3960 if (ssa_var >= 0 && ssa->vars[ssa_var].var == var_num) { in zend_jit_find_ssa_var()
3961 return ssa_var; in zend_jit_find_ssa_var()
3969 ssa_var = -1; in zend_jit_find_ssa_var()
3972 ssa_var = phi->ssa_var; in zend_jit_find_ssa_var()
3976 if (ssa_var >= 0) { in zend_jit_find_ssa_var()
3977 return ssa_var; in zend_jit_find_ssa_var()
3998 ssa_var = ssa_op->result_def; in zend_jit_find_ssa_var()
3999 if (ssa_var >= 0 && ssa->vars[ssa_var].var == var_num) { in zend_jit_find_ssa_var()
4002 ssa_var = ssa_op->op2_def; in zend_jit_find_ssa_var()
4003 if (ssa_var >= 0 && ssa->vars[ssa_var].var == var_num) { in zend_jit_find_ssa_var()
4006 ssa_var = ssa_op->op1_def; in zend_jit_find_ssa_var()
4007 if (ssa_var >= 0 && ssa->vars[ssa_var].var == var_num) { in zend_jit_find_ssa_var()
4017 ssa_var = -1; in zend_jit_find_ssa_var()
4020 ssa_var = phi->ssa_var; in zend_jit_find_ssa_var()
4024 if (ssa_var >= 0) { in zend_jit_find_ssa_var()
4032 ssa_var = -1; in zend_jit_find_ssa_var()
4036 return ssa_var; in zend_jit_find_ssa_var()
4046 int ssa_var = zend_jit_find_ssa_var(op_array, ssa, opline_num, var_num); in zend_jit_trace_must_store_type() local
4048 if (ssa_var >= 0) { in zend_jit_trace_must_store_type()
4049 if ((ssa->var_info[ssa_var].type & (MAY_BE_ANY|MAY_BE_UNDEF)) != (1U << type)) { in zend_jit_trace_must_store_type()
4239 && !(ssa->var_info[ssa->vars[i].phi_use_chain->ssa_var].type & MAY_BE_GUARD)))) { in zend_jit_trace()
4261 && !(ssa->var_info[ssa->vars[i].phi_use_chain->ssa_var].type & MAY_BE_PACKED_GUARD)))) { in zend_jit_trace()
4327 if (RA_HAS_REG(phi->ssa_var) in zend_jit_trace()
4328 && !(RA_REG_FLAGS(phi->ssa_var) & ZREG_LOAD)) { in zend_jit_trace()
4330 SET_STACK_REF(stack, phi->var, ra[phi->ssa_var].ref); in zend_jit_trace()
4337 if (RA_HAS_REG(phi->ssa_var)) { in zend_jit_trace()
4338 if (RA_REG_FLAGS(phi->ssa_var) & ZREG_LOAD) { in zend_jit_trace()
4339 uint32_t info = ssa->var_info[phi->ssa_var].type; in zend_jit_trace()
4346 ssa->var_info[phi->ssa_var].type = info; in zend_jit_trace()
4349 …if (!zend_jit_load_var(&ctx, ssa->var_info[phi->ssa_var].type, ssa->vars[phi->ssa_var].var, phi->s… in zend_jit_trace()
4352 SET_STACK_REF_EX(stack, phi->var, ra[phi->ssa_var].ref, ZREG_LOAD); in zend_jit_trace()
4353 } else if (RA_REG_FLAGS(phi->ssa_var) & ZREG_STORE) { in zend_jit_trace()
4355 …f (!zend_jit_store_var(&ctx, ssa->var_info[phi->ssa_var].type, ssa->vars[phi->ssa_var].var, phi->s… in zend_jit_trace()
4356 STACK_MEM_TYPE(stack, phi->var) != ssa->var_info[phi->ssa_var].type)) { in zend_jit_trace()
4359 SET_STACK_REF_EX(stack, phi->var, ra[phi->ssa_var].ref, ZREG_STORE); in zend_jit_trace()
4362 SET_STACK_REF(stack, phi->var, ra[phi->ssa_var].ref); in zend_jit_trace()
7190 if (!RA_HAS_REG(phi->ssa_var) in zend_jit_trace()
7191 || (RA_REG_FLAGS(phi->ssa_var) & (ZREG_LOAD|ZREG_STORE)) == 0) { in zend_jit_trace()
7826 zend_dump_ssa_var(op_array, tssa, p->ssa_var, 0, p->var, ZEND_DUMP_RC_INFERENCE); in zend_jit_dump_trace()