@@ -11178,29 +11178,31 @@ static int zend_jit_fetch_this(dasm_State **Dst, const zend_op *opline, const ze
11178
11178
{
11179
11179
zend_jit_addr res_addr = RES_ADDR();
11180
11180
11181
- if (JIT_G(trigger) == ZEND_JIT_ON_HOT_TRACE) {
11182
- if (!JIT_G(current_frame) ||
11183
- !TRACE_FRAME_IS_THIS_CHECKED(JIT_G(current_frame))) {
11181
+ if (!op_array->scope || (op_array->fn_flags & ZEND_ACC_STATIC)) {
11182
+ if (JIT_G(trigger) == ZEND_JIT_ON_HOT_TRACE) {
11183
+ if (!JIT_G(current_frame) ||
11184
+ !TRACE_FRAME_IS_THIS_CHECKED(JIT_G(current_frame))) {
11184
11185
11185
- int32_t exit_point = zend_jit_trace_get_exit_point(opline, opline, NULL, ZEND_JIT_EXIT_TO_VM);
11186
- const void *exit_addr = zend_jit_trace_get_exit_addr(exit_point);
11186
+ int32_t exit_point = zend_jit_trace_get_exit_point(opline, opline, NULL, ZEND_JIT_EXIT_TO_VM);
11187
+ const void *exit_addr = zend_jit_trace_get_exit_addr(exit_point);
11187
11188
11188
- | cmp byte EX->This.u1.v.type, IS_OBJECT
11189
- | jne &exit_addr
11189
+ | cmp byte EX->This.u1.v.type, IS_OBJECT
11190
+ | jne &exit_addr
11190
11191
11191
- if (JIT_G(current_frame)) {
11192
- TRACE_FRAME_SET_THIS_CHECKED(JIT_G(current_frame));
11192
+ if (JIT_G(current_frame)) {
11193
+ TRACE_FRAME_SET_THIS_CHECKED(JIT_G(current_frame));
11194
+ }
11193
11195
}
11194
- }
11195
- } else {
11196
+ } else {
11196
11197
11197
- | cmp byte EX->This.u1.v.type, IS_OBJECT
11198
- | jne >1
11199
- |.cold_code
11200
- |1:
11201
- | SAVE_VALID_OPLINE opline, r0
11202
- | jmp ->invalid_this
11203
- |.code
11198
+ | cmp byte EX->This.u1.v.type, IS_OBJECT
11199
+ | jne >1
11200
+ |.cold_code
11201
+ |1:
11202
+ | SAVE_VALID_OPLINE opline, r0
11203
+ | jmp ->invalid_this
11204
+ |.code
11205
+ }
11204
11206
}
11205
11207
11206
11208
| mov r0, aword EX->This.value.ptr
0 commit comments