From 31258e4550be4d91502593f045463e7ca5e3715a Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 9 Jul 2020 18:54:36 +0300 Subject: [PATCH] Fixed register allocation for tests/lang/operators/preinc_basiclong_64bit.phpt --- ext/opcache/jit/zend_jit_trace.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/ext/opcache/jit/zend_jit_trace.c b/ext/opcache/jit/zend_jit_trace.c index 880a2c4b68..b1d910c534 100644 --- a/ext/opcache/jit/zend_jit_trace.c +++ b/ext/opcache/jit/zend_jit_trace.c @@ -2122,9 +2122,12 @@ static zend_lifetime_interval** zend_jit_trace_allocate_registers(zend_jit_trace || opline->opcode == ZEND_ADD || opline->opcode == ZEND_SUB || opline->opcode == ZEND_MUL) { - start[ssa_op->result_def] = idx; - vars_op_array[ssa_op->result_def] = op_array; - count++; + if (!(ssa->var_info[ssa_op->result_def].type & MAY_BE_DOUBLE) + || (opline->opcode != ZEND_PRE_INC && opline->opcode != ZEND_PRE_DEC)) { + start[ssa_op->result_def] = idx; + vars_op_array[ssa_op->result_def] = op_array; + count++; + } } } if (ssa_op->op1_def >= 0 -- 2.50.1