Skip to content

Commit 5d9063a

Browse files
committed
Fixed tracing JIT for CALL VM without global register variables
1 parent 2414b3d commit 5d9063a

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

ext/opcache/jit/zend_jit_x86.dasc

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3021,12 +3021,18 @@ static int zend_jit_trace_return(dasm_State **Dst, zend_bool original_handler)
30213021
| jmp aword [IP + r0]
30223022
}
30233023
} else {
3024+
if (original_handler) {
3025+
| mov FCARG1a, FP
3026+
| mov r0, EX->func
3027+
| mov r0, aword [r0 + offsetof(zend_op_array, reserved[zend_func_info_rid])]
3028+
| mov r0, aword [r0 + offsetof(zend_jit_op_array_trace_extension, offset)]
3029+
| call aword [IP + r0]
3030+
}
30243031
| mov FP, aword T2 // restore FP
30253032
| mov RX, aword T3 // restore IP
30263033
| add r4, NR_SPAD // stack alignment
30273034
| mov r0, 2 // ZEND_VM_LEAVE
30283035
| ret
3029-
// TODO: support for "original_handler" ????
30303036
}
30313037
#endif
30323038
return 1;

0 commit comments

Comments
 (0)