You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
supercooldave edited this page Dec 9, 2014
·
1 revision
Each encore active object is mapped to a single pony actor.
A pony actor for class C has associated with it the method table for class C,
and each method in that table has a corresponding pony level message that
is used by clients to call the method.
Each method immediately returns a future. When a method is run, the value
is dumped in the future object.
When some code wants to do a get (or await) on a future and the future is not
ready, the stack and registers are copied into a data structure (essentially
creating a continuation) and this is saved with the future.
[The difference between a get and an await is that with a get the actor is
“descheduled”, meaning that no thread will run it.]
When a future is subsequently fulfilled, the saved “continuation” is pushed
onto the queue of the corresponding actor. The actor is then “rescheduled”.