search for: runtimeyield

Displaying 1 result from an estimated 1 matches for "runtimeyield".

2020 Mar 27
2
Efficient Green Thread Context-Switching
...ponsible for managing many (perhaps millions) of green threads. Essentially, the program flow is like this: 1. Program is executing Green Thread 1 (GT1) 2. Program reaches a "yield point" which does three things: a. Saves all active registers to the stack. b. Calls a runtime function runtimeYield(). c. Pops the saved registers from the stack, restoring the original CPU state (we'll get to this later). 3. The runtimeYield function is called with a calling convention that stores the return address on top of the stack. 4. Inside runtimeYield, we record the stack pointer (%rsp) within a q...