Changes between Version 6 and Version 7 of DataParallel/ClosureConversion


Ignore:
Timestamp:
Apr 20, 2007 11:38:37 AM (7 years ago)
Author:
chak
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DataParallel/ClosureConversion

    v6 v7  
    2727 
    2828''Classes.'' 
    29 Moreover, if the closure-converted code uses a type class, we need a closure-converted type class.  It might appear that this is a non-issue on Core as classes have already been desugared to plain System F.  The trouble is that GHC does not use plain System F.  It extends it by a whole array of extra type features.  In particular, classes induce datatype declarations., and yhey almost always contain arrow types.  Hence, as we just discussed, they need to be transformed.  Matters are complicated by GHC not actually generating standalone datatypes declarations that are emitted into interface files, a class declaration siliently implies a data declaration - GHC calls this an ''iface declaration sub-binder''.  So, it appears best to create for every class as closure-converted class that - as all other class declarations - implies the closure-converted class representation datatype. 
     29Moreover, if the closure-converted code uses a type class, we need a closure-converted type class.  It might appear that this is a non-issue on Core as classes have already been desugared to plain System F.  The trouble is that GHC does not use plain System F.  It extends it by a whole array of extra type features.  In particular, classes induce datatype declarations., and yhey almost always contain arrow types.  Hence, as we just discussed, they need to be transformed.  Matters are complicated by GHC not actually generating standalone datatypes declarations that are emitted into interface files, a class declaration siliently implies a data declaration - GHC calls this an ''iface declaration sub-binder''.  So, it appears best to create for every class a closure-converted class that - as all other class declarations - implies the closure-converted class representation datatype. 
     30 
     31''Instances.'' 
     32When we call overloaded closure-converted functions, we need to supply closure-converted dictionaries; i.e., closure-converted dfuns.   
    3033 
    3134==== Interface files ==== 
    3235 
     36How much information do we want to put into interface files?  For example, for type declarations, we can add the closure-converted declaration to the interface file or we can only add the vanilla one and have the importing modules derive the converted form on the fly during iface type checking - similar to how iface declaration sub-binders are generated on the fly, instead of being put into the interface files. 
     37 
     38==== Mixing converted and vanilla code ==== 
     39 
     40==== An alternative: one-the-fly closure conversion ==== 
    3341 
    3442----