Changes between Version 54 and Version 55 of LightweightConcurrency


Ignore:
Timestamp:
May 19, 2012 2:56:44 AM (3 years ago)
Author:
kc
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • LightweightConcurrency

    v54 v55  
    44 
    55Lightweight concurrency implementation resides in the `ghc-lwc` branch in the git repo. 
     6 
     7== Table of Contents == 
     8 
     9 * [#TableofContents Table of Contents] 
     10 * [#Introduction Introduction] 
     11 * [#Background-GHCsConcurrencyRTS Background - GHC's Concurrency RTS] 
     12   * [#ConcurrencySubstrate Concurrency Substrate] 
     13     * [#PTM PTM] 
     14     * [#One-shotContinuations One-shot Continuations] 
    615 
    716== Introduction ==  
     
    4251A PTM transaction may allocate, read and write transactional variables of type `PVar a`. It is important to notice that PTM does not provide a blocking `retry` mechanism. Such a blocking action needs to interact with the scheduler, to block the current thread and resume another thread. We will see [#AbstractSchedulerInterface later] how to allow such interactions while not imposing any restriction on the structure of the schedulers. 
    4352 
    44 === One-shot continuations === 
     53=== One-shot Continuations === 
    4554 
    4655The concurrency substrate enables creation and scheduling of I/O-performing computations through ''one-shot continuations''. An SCont (stack continuation) is a suspended I/O computation, which is in fact just a reference to a TSO object. Capturing the current continuation is just getting a reference to the current TSO, and hence is very fast. SCont interface is shown below: