diff options
author | Dmitry Stogov <dmitry@zend.com> | 2020-09-17 18:36:45 +0300 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2020-09-17 18:36:45 +0300 |
commit | 23429b58182f437cd84078364c20b12d14c70c08 (patch) | |
tree | 85e13284125671b3ceb343dddd62601a0b1ba926 | |
parent | bfa8e42a5550cdd0545259cc34cf36152c3e1b08 (diff) | |
download | php-git-23429b58182f437cd84078364c20b12d14c70c08.tar.gz |
Fixed incorrect register allocation
-rw-r--r-- | ext/opcache/jit/zend_jit_x86.dasc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/opcache/jit/zend_jit_x86.dasc b/ext/opcache/jit/zend_jit_x86.dasc index 4fccf22d38..20fe88e9c1 100644 --- a/ext/opcache/jit/zend_jit_x86.dasc +++ b/ext/opcache/jit/zend_jit_x86.dasc @@ -15185,6 +15185,9 @@ static zend_regset zend_jit_get_scratch_regset(const zend_op *opline, const zend if (!(op1_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF)-(MAY_BE_LONG|MAY_BE_DOUBLE))) && !(op2_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF)-(MAY_BE_LONG|MAY_BE_DOUBLE)))) { regset = ZEND_REGSET_EMPTY; + if (!(opline->result_type & (IS_SMART_BRANCH_JMPZ|IS_SMART_BRANCH_JMPNZ))) { + ZEND_REGSET_INCL(regset, ZREG_R0); + } if ((op1_info & MAY_BE_LONG) && (op2_info & MAY_BE_LONG) && opline->op1_type != IS_CONST && opline->op2_type != IS_CONST) { if (ssa_op->op1_use != current_var && |