Skip to content

Commit bf58e06

Browse files
committed
JIT/x86: disable register allocation for expected ++/-- overflow case.
This fixes ext/opcache/tests/jit/inc_021.phpt with tracing JIT.
1 parent 9edcde2 commit bf58e06

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

ext/opcache/jit/zend_jit_x86.dasc

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15357,7 +15357,10 @@ static bool zend_jit_opline_supports_reg(const zend_op_array *op_array, zend_ssa
1535715357
case ZEND_POST_INC:
1535815358
case ZEND_POST_DEC:
1535915359
op1_info = OP1_INFO();
15360-
return opline->op1_type == IS_CV && !(op1_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF) - MAY_BE_LONG));
15360+
op2_info = OP1_DEF_INFO();
15361+
return opline->op1_type == IS_CV
15362+
&& !(op1_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF) - MAY_BE_LONG))
15363+
&& (op2_info & MAY_BE_LONG);
1536115364
case ZEND_BOOL:
1536215365
case ZEND_BOOL_NOT:
1536315366
case ZEND_JMPZ:

0 commit comments

Comments
 (0)