You cache a zend_fcall_info for some user-provided callback (let's call it Bob) and you have a function which will call that callback (let's call it Alice).
1. Alice is called.
callstack: [A]
2. In order to call Bob, Alice gives zend_call_function a pointer to the cached zend_fcall_info. zend_call_function modifies the struct to contain the parameters being passed.
callstack: [A, B]
3. Bob calls Alice.
callstack: [A, B, A]
4. In order to call Bob, Alice gives zend_call_function a pointer to the same cached zend_fcall_info. zend_call_function modifies the struct to contain the parameters be…