Changes between Version 3 and Version 4 of DataParallel/ClosureConversion


Ignore:
Timestamp:
Apr 17, 2007 10:59:51 AM (8 years ago)
Author:
guest
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DataParallel/ClosureConversion

    v3 v4  
    55=== Closure-converted types as indexed-types ===
    66
    7 After some brainstorming, Roman and I (= Manuel) came to the conclusion that we can save ourselves a lot of bookkeeping if we can represent closure-converted types by indexed types (i.e., keeping track of which original types correspond to which converted types).  The idea is to use a class
    8 {{{
    9 class CC a where
    10   data CConv a        -- closure converted 'a'
    11   to :: a -> CConv a
    12   fr :: CConv a -> a
    13 }}}
    14 The most interesting instance is that for functions, which reads
    15 {{{
    16 data Clo a b = forall e. Clo (c -> a -> b) e
    17 
    18 class (CC a, CC b) => CC (a -> b) where
    19   data CConv (a -> b) = CCArrow (Clo a b)
    20   to f = Clo (\_ -> f) ()
    21   fr (Clo f e) = f e
    22 }}}
     7After some brainstorming, Roman and I (= Manuel) came to the conclusion that we can save ourselves a lot of bookkeeping if we can represent closure-converted types by indexed types (i.e., keeping track of which original types correspond to which converted types).  The details are under [wiki:DataParallel/ClosureConversion/Indexed indexed closure conversion].
    238
    249=== From the Skype discussion, 16 Mar 07 ===