]> granicus.if.org Git - php/commitdiff
Update abstarct stack before guard to keep proper type in side trace
authorDmitry Stogov <dmitry@zend.com>
Mon, 27 Jul 2020 21:14:28 +0000 (00:14 +0300)
committerDmitry Stogov <dmitry@zend.com>
Mon, 27 Jul 2020 21:14:28 +0000 (00:14 +0300)
ext/opcache/jit/zend_jit_trace.c

index e558a487052267d86fcf02ad28a78fbd199e77fc..abedddec7c6d5417557a2999594593ce7d665b36 100644 (file)
@@ -4125,6 +4125,7 @@ static const void *zend_jit_trace(zend_jit_trace_rec *trace_buffer, uint32_t par
                                                }
                                                if (opline->op1_type != IS_CONST
                                                 && (p+1)->op == ZEND_JIT_TRACE_INIT_CALL && (p+1)->func) {
+                                                       SET_STACK_TYPE(stack, EX_VAR_TO_NUM(opline->result.var), IS_OBJECT);
                                                        if (!zend_jit_init_fcall_guard(&dasm_state, opline, (p+1)->func, opline+1)) {
                                                                goto jit_failure;
                                                        }