Skip to content

Commit b00ef4e

Browse files
committed
Fix fuzzer runner
We must take into account the calling convention of the tailcall vm.
1 parent 326c254 commit b00ef4e

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

sapi/fuzzer/fuzzer-execute-common.h

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,6 @@
3232
static uint32_t steps_left;
3333
static bool bailed_out = false;
3434

35-
/* Because the fuzzer is always compiled with clang,
36-
* we can assume that we don't use global registers / hybrid VM. */
37-
typedef zend_op *(ZEND_FASTCALL *opcode_handler_t)(zend_execute_data *, const zend_op *);
38-
3935
static zend_always_inline void fuzzer_bailout(void) {
4036
bailed_out = true;
4137
zend_bailout();
@@ -67,7 +63,7 @@ static void fuzzer_execute_ex(zend_execute_data *execute_data) {
6763

6864
while (1) {
6965
fuzzer_step();
70-
opline = ((opcode_handler_t) opline->handler)(execute_data, opline);
66+
opline = opline->handler(execute_data, opline);
7167
if ((uintptr_t) opline & ZEND_VM_ENTER_BIT) {
7268
opline = (const zend_op *) ((uintptr_t) opline & ~ZEND_VM_ENTER_BIT);
7369
if (opline) {

0 commit comments

Comments
 (0)