goto jit_failure;
}
if (opline->op1_type == IS_CV
- && ssa->vars[ssa_op->op1_use].alias == NO_ALIAS) {
- ssa->var_info[ssa_op->op1_use].guarded_reference = 1;
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
}
} else {
CHECK_OP1_TRACE_TYPE();
goto jit_failure;
}
if (opline->op1_type == IS_CV
- && ssa->vars[ssa_op->op1_use].alias == NO_ALIAS) {
- ssa->var_info[ssa_op->op1_use].guarded_reference = 1;
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
}
} else {
CHECK_OP1_TRACE_TYPE();
goto jit_failure;
}
if (opline->op1_type == IS_CV
- && ssa->vars[ssa_op->op1_use].alias == NO_ALIAS) {
- ssa->var_info[ssa_op->op1_use].guarded_reference = 1;
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
}
} else {
CHECK_OP1_TRACE_TYPE();
goto jit_failure;
}
if (opline->op1_type == IS_CV
- && ssa->vars[ssa_op->op1_use].alias == NO_ALIAS) {
- ssa->var_info[ssa_op->op1_use].guarded_reference = 1;
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
}
} else {
CHECK_OP1_TRACE_TYPE();
zend_may_throw(opline, ssa_op, op_array, ssa))) {
goto jit_failure;
}
+ if ((opline+1)->op1_type == IS_CV
+ && (ssa_op+1)->op1_def >= 0
+ && ssa->vars[(ssa_op+1)->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[(ssa_op+1)->op1_def].guarded_reference = ssa->var_info[(ssa_op+1)->op1_use].guarded_reference;
+ }
goto done;
case ZEND_ASSIGN_DIM:
op1_info = OP1_INFO();
goto jit_failure;
}
if (opline->op1_type == IS_CV
- && ssa->vars[ssa_op->op1_use].alias == NO_ALIAS) {
- ssa->var_info[ssa_op->op1_use].guarded_reference = 1;
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
}
} else {
CHECK_OP1_TRACE_TYPE();
zend_may_throw_ex(opline, ssa_op, op_array, ssa, op1_info, op2_info))) {
goto jit_failure;
}
+ if ((opline+1)->op1_type == IS_CV
+ && (ssa_op+1)->op1_def >= 0
+ && ssa->vars[(ssa_op+1)->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[(ssa_op+1)->op1_def].guarded_reference = ssa->var_info[(ssa_op+1)->op1_use].guarded_reference;
+ }
goto done;
case ZEND_ASSIGN:
if (opline->op1_type != IS_CV) {
goto jit_failure;
}
if (opline->op1_type == IS_CV
- && ssa->vars[ssa_op->op1_use].alias == NO_ALIAS) {
- ssa->var_info[ssa_op->op1_use].guarded_reference = 1;
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
}
if (!zend_jit_assign_to_typed_ref(&dasm_state, opline, opline->op2_type, op2_addr, 1)) {
goto jit_failure;
zend_may_throw_ex(opline, ssa_op, op_array, ssa, op1_info, op2_info))) {
goto jit_failure;
}
+ if (opline->op2_type == IS_CV
+ && ssa_op->op2_def >= 0
+ && ssa->vars[ssa_op->op2_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op2_def].guarded_reference = ssa->var_info[ssa_op->op2_use].guarded_reference;
+ }
goto done;
case ZEND_CAST:
if (opline->extended_value != op1_type) {
res_use_info, res_info, RES_REG_ADDR())) {
goto jit_failure;
}
+ if (opline->op1_type == IS_CV
+ && ssa_op->op1_def >= 0
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = ssa->var_info[ssa_op->op1_use].guarded_reference;
+ }
goto done;
case ZEND_INIT_FCALL:
case ZEND_INIT_FCALL_BY_NAME:
op1_info, 0)) {
goto jit_failure;
}
+ if (opline->op1_type == IS_CV
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
+ }
goto done;
case ZEND_SEND_VAR:
case ZEND_SEND_VAR_EX:
op1_info, op1_addr, op1_def_addr)) {
goto jit_failure;
}
+ if (opline->op1_type == IS_CV
+ && ssa_op->op1_def >= 0
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = ssa->var_info[ssa_op->op1_use].guarded_reference;
+ }
if (frame->call
&& frame->call->func
&& frame->call->func->type == ZEND_USER_FUNCTION) {
goto jit_failure;
}
if (opline->op1_type == IS_CV
- && ssa->vars[ssa_op->op1_use].alias == NO_ALIAS) {
- ssa->var_info[ssa_op->op1_use].guarded_reference = 1;
+ && ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
}
} else {
CHECK_OP1_TRACE_TYPE();
}
if (opline->op1_type == IS_CV
&& ssa->vars[ssa_op->op1_use].alias == NO_ALIAS) {
- ssa->var_info[ssa_op->op1_use].guarded_reference = 1;
+ ssa->var_info[ssa_op->op1_def >= 0 ? ssa_op->op1_def : ssa_op->op1_use].guarded_reference = 1;
}
} else {
CHECK_OP1_TRACE_TYPE();
} else {
op1_info = OP1_INFO();
}
+ if (ssa->vars[ssa_op->op1_def].alias == NO_ALIAS) {
+ ssa->var_info[ssa_op->op1_def].guarded_reference = 1;
+ }
if (!zend_jit_bind_global(&dasm_state, opline, op1_info)) {
goto jit_failure;
}