Skip to content

Commit 738b5c4

Browse files
committed
Try to make the change more targeted
Somehow this resulted in even more test failures. Avoid the refactoring to use zend_may_throw in case that causes an issue.
1 parent 8ca0ef6 commit 738b5c4

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Zend/Optimizer/zend_inference.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4516,7 +4516,6 @@ ZEND_API int zend_may_throw_ex(const zend_op *opline, const zend_ssa_op *ssa_op,
45164516
case ZEND_ISSET_ISEMPTY_CV:
45174517
case ZEND_MAKE_REF:
45184518
case ZEND_FETCH_DIM_W:
4519-
case ZEND_FETCH_LIST_W:
45204519
break;
45214520
default:
45224521
/* undefined variable warning */

ext/opcache/jit/zend_jit_trace.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5196,7 +5196,10 @@ static const void *zend_jit_trace(zend_jit_trace_rec *trace_buffer, uint32_t par
51965196
op1_def_info = OP1_DEF_INFO();
51975197
if (!zend_jit_fetch_dim(&dasm_state, opline,
51985198
op1_info, op1_addr, op2_info, RES_REG_ADDR(),
5199-
(zend_may_throw_ex(opline, ssa_op, op_array, ssa, op1_info, op2_info)
5199+
(opline->opcode == ZEND_FETCH_DIM_RW
5200+
|| opline->op2_type == IS_UNUSED
5201+
|| (op1_info & (MAY_BE_FALSE|MAY_BE_TRUE|MAY_BE_LONG|MAY_BE_DOUBLE|MAY_BE_STRING|MAY_BE_OBJECT|MAY_BE_RESOURCE|MAY_BE_REF))
5202+
|| (op2_info & (MAY_BE_UNDEF|MAY_BE_RESOURCE|MAY_BE_ARRAY|MAY_BE_OBJECT))
52005203
|| (opline->op1_type == IS_VAR
52015204
&& (op1_info & MAY_BE_UNDEF)
52025205
&& !ssa->var_info[ssa_op->op1_use].indirect_reference)))) {

0 commit comments

Comments
 (0)