Changes between Version 14 and Version 15 of Commentary/Compiler/NewCodeGenPipeline


Ignore:
Timestamp:
Aug 27, 2008 8:05:35 AM (6 years ago)
Author:
simonpj
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Commentary/Compiler/NewCodeGenPipeline

    v14 v15  
    1212   * Control-flow blocks: `Block` 
    1313   * Control-flow graphs: `Graph`[[BR]][[BR]] 
    14  * '''`ZipDataFlow`''' contains a generic framework for solving dataflow problems over `ZipCfg`.[[BR]][[BR]] 
     14 * '''`ZipDataFlow`''' contains a generic framework for solving dataflow problems over `ZipCfg`. It allows you to define a new optimization simply by defining a lattice of dataflow facts (akin to a specialized logic) and then writing the dataflow-transfer functions found in compiler textbooks. Handing these functions to the dataflow engine produces a new optimization that is not only useful on its own, but that can easily be composed with other optimizations to create an integrated "superoptimization" that is strictly more powerful than any sequence of individual optimizations, no matter how many times they are re-run.  The dataflow engine is based on [http://citeseer.ist.psu.edu/old/lerner01composing.html (Lerner, Grove, and Chambers 2002)]; you can find a functional implementation of the dataflow engine presented in [http://www.cs.tufts.edu/~nr/pubs/zipcfg-abstract.html (Ramsey and Dias 2005)].[[BR]][[BR]] 
    1515 * '''[[GhcFile(compiler/cmm/ZipCfgCmmRep.hs)]]''' instantiates `ZipCfg` for Cmm, by defining types `Middle` and `Last` and using these to instantiate the polymorphic fields of `ZipCfg`.  It also defines a bunch of smart constructor (`mkJump`, `mkAssign`, `mkCmmIfThenElse` etc) which make it easy to build `CmmGraph`.[[BR]][[BR]] 
    1616 * '''`CmmExpr`''' contains the data types for Cmm expressions, registers, and the like.  It does not depend on the dataflow framework at all.