From: Dmitry Stogov Date: Tue, 26 Jan 2021 18:31:15 +0000 (+0300) Subject: Fixed observer API and JIT compatibility X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=64622979f94bbc7b976bbd67d610004d050cdec3;p=php Fixed observer API and JIT compatibility --- diff --git a/ext/opcache/jit/zend_jit_x86.dasc b/ext/opcache/jit/zend_jit_x86.dasc index 91038b1be4..93e95886aa 100644 --- a/ext/opcache/jit/zend_jit_x86.dasc +++ b/ext/opcache/jit/zend_jit_x86.dasc @@ -11432,6 +11432,14 @@ static int zend_jit_return(dasm_State **Dst, const zend_op *opline, const zend_o } if (ZEND_OBSERVER_ENABLED) { + if (Z_MODE(op1_addr) == IS_REG) { + zend_jit_addr dst = ZEND_ADDR_MEM_ZVAL(ZREG_FP, opline->op1.var); + + if (!zend_jit_spill_store(Dst, op1_addr, dst, op1_info, 1)) { + return 0; + } + op1_addr = dst; + } | LOAD_ZVAL_ADDR FCARG2a, op1_addr | mov FCARG1a, FP | SET_EX_OPLINE opline, r0