Response times in asynchronous I/O-based software using thread pairing and co-execution
AssigneeInternational Business Machines Corporation
InventorsMichael H. Dawson, Gireesh Punathil
Life of this patent
Estimating the term…
Abstract
Methods and systems for pre-fetching operations include executing event callbacks in an event loop using a processor until execution stops on a polling request. A path walk is performed on future events in the event loop until the polling request returns to pre-fetch information for the future events into a processor cache associated with the processor. Execution of the event callbacks in the event loop is resumed after the polling request returns.
Claims20
A method for pre-fetching operations, comprising:
- executing event callbacks in an event loop using a processor;
- halting execution of the new event callbacks due to a polling request;
- performing a path walk on future events in the event loop to pre-fetch information for the future events into a processor cache associated with the processor, the path walk including approximations, wherein the approximations include a different code flow path and a different set of objects than used by the main thread;
- determining that the polling request has returned;
- halting the path walk after determining that the polling request has returned;
- and
- resuming execution of the event callbacks in the event loop after the polling request returns.
A computer program product for pre-fetching operations, the computer program product comprising a computer readable storage medium having program instructions embodied therewith, the program instructions readable by a computer to cause the computer to:
- execute event callbacks in an event loop using a processor;
- halt execution of the event callbacks due to a polling request;
- perform a path walk on future events in the event loop to pre-fetch information for the future events into a processor cache associated with the processor, the path walk including approximations, wherein the approximations include a different code flow path and a different set of objects than used by the main thread;
- determine that the polling request has returned;
- halt the path walk after determining that the polling request has returned;
- and
- resume execution of the event callbacks in the event loop after the polling request returns.
A system for pre-fetching operations, comprising:
- a processor cache;
- a processor, associated with the processor cache, configured to:
- execute event callbacks in an event loop until execution of new event callbacks stops due to a polling request,
- perform a path walk on future events in the event loop to pre-fetch information for the future events into the processor cache, the path walk including approximations, wherein the approximations include a different code flow path and a different set of objects than used by the main thread,
- determine that the polling request has returned,
- halt the path walk after the polling request is determined to have returned, and
- resume execution of the event callbacks in the event loop after the polling request returns.
Dependencies are inferred from the claim text.