Changes between Version 1 and Version 2 of DataParallel/Library


Ignore:
Timestamp:
May 14, 2009 9:22:59 AM (5 years ago)
Author:
simonpj
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DataParallel/Library

    v1 v2  
     1= The DPH packages = 
     2 
     3This page describes the packages (aka libraries) that form part of DPH, enumerates all the wyas in which they differ from "normal" GHC packages, and says what stuff lives where. 
     4 
     5== What packages there are == 
     6 
     7DPH comes with the following blobs of source code: 
     8 
     9  * `dph/dph-prim-seq` implements the DPH Primitive Interface for sequential machines.  Compiling it yields package `dph-prim-seq`. 
     10 
     11  * `dph/dph-prim-par` implements the DPH Primitive Interface for parallel machines.  Compiling it yields package `dph-prim-seq`. 
     12 
     13  * `dph/dph-base` implements the DPH User Interface, by importing the DPH Primitive Interface. The same source code can be compiled in two ways:  
     14     * Importing `dph-prim-seq`, generating package `dph-base-seq` 
     15     * Importing `dph-prim-seq`, generating package `dph-base-seq` 
     16 
     17'''SLPJ: what is dph-common?''' 
     18 
     19The DPH libraries (in particular `dph-base`) use Template Haskell, so they can only be compiled with a stage2 compiler. 
     20 
     21== How the DPH packages are coupled to GHC == 
     22 
     23GHC knows about DPH as follows.  A single flag `-dph` switches on the following: 
     24 
     25  * Adds `-package dph` ('''SLPJ: correct?'''), so that the user can `import Data.Array.Parallel`.  And so that the right package gets linked in the link step. 
     26 
     27  * Runs a special pass called the '''vectoriser'''.  This pass generates code that mentions (by Original Name) various functions defined in `dph-prim-seq` or `dph-prim-par` (depending on the compiler flag used).  So if you change where a function is defined in `dph-prim-*`, or the name of the function, you have to make a corresponding change in GHC. 
     28 
     29'''SLPJ: is it correct that GHC only generates Names in dph-prim?  If not, could it be made true?''' 
     30 
    131== Array library of flat and segmented operations == 
    232