Changes between Version 15 and Version 16 of Status/May11

Apr 29, 2011 7:48:08 AM (4 years ago)



  • Status/May11

    v15 v16  
    66GHC is still busy as ever. The GHC 7.0 branch has come and gone, and now that the branch has been closed we have finally made the long-planned switch from darcs to git. Meanwhile, we are busily working towards the 7.2 branch, and hope to make the 7.2.1 release in June. Some of the forthcoming highlights are:
    8  * '''Simon PJ: New coercions'''
     8 * GHC's intermediate language (which we call "Core") is a simple,
     9   explicitly-typed lambda in the style of System F.  Core is far,
     10   far simpler than Haskell (`CoreExpr` has only eight data
     11   constructors), so GHC can type-check Core very fast and reliably.
     12   In theory, such a typecheck is redundant (since the original
     13   Haskell program was typechecked), but in practice, typechecking
     14   Core is a very powerful internal consistency check on GHC itself:
     15   many compiler bugs generate type-incorrect Core. This consistency
     16   check is run by `-dcore-lint`.
    10  * '''Simon PJ: generics'''
     18 With the advent of GADTs and type families, the type system of the
     19 Core necessarily has to become a bit more complicated.  For a few
     20 years wa have been using an extension of System F, called System
     21 FC, as described in our paper [FC}.  However, the way that System FC
     22 was actually ''implemented'' in GHC's Core language was a bit unsatisfactory
     23 so, with help from Brent Yorgey, Simon PJ is busy re-engineering it.
     24 In particular, FC has ''coercion terms'', and these will now
     25 be represented by their own data type `Coercion`, rather than being
     26 squeezed into `Type`.  Moreover, these coercion terms can get big,
     27 so there's a new "coercion optimiser" to replace big coercions by
     28 equivalent smaller ones. All this is described in our new paper [New FC].
     29 These changes will (finally) complete the type-family story by
     30 making so-called "equality superclasses" work for the first time.
     32 * In the autumn, Dimitrios and Simon PJ implemented a completely
     33   new constraint solver for the type checker; we also complete an
     34   epic JFP paper describing how it works [OutsideIn].  The new
     35   solver is far more tractable and maintainable than the old type
     36   checker, and has fixed many outstanding problems.  We are still
     37   shaking out the last bugs, and we have some ideas for improving
     38   performance.  Based on this new foundation, we are planning to
     39   develop the type system further, notably by adding a richer kind
     40   system along the lines of Conor McBride's SHE system [SHE].
     42 * Pedro Magalhaes has nearly completed his implementation of the
     43   '''derivable type classes''' mechanism described in his 2010
     44   Haskell Symposium paper [Derivable].  It will be in GHC 7.2.
     46 * Edward Yang has done a lot of work on the long-promised new
     47   code-generation path.  Hoopl is now fully part of GHC, and
     48   the new path uses it extensively.  We are now working on making
     49   the new pipeline generate better code than the old one.  Stay
     50   tuned. * '''Simon PJ: New coercions'''
    1254 * '''Simon PJ: Any update? Any regressions remaining?''' Previous entry: ''As long promised, Simon PJ and Dimitrios have spent a good chunk of the summer doing a '''complete rewrite of the constraint solver in the type inference engine'''.  Because of GHC's myriad type-system extensions, especially GADTs and type families, the old engine had begun to resemble the final stages of a game of Jenga.  It was a delicately-balanced pile of blocks that lived in constant danger of complete collapse, and had become extremely different to modify (or even to understand).  The new inference engine is much more modular and robust; it is described in detail in our paper [[ OutsideIn]].  A blog post describes some consequential changes to let generalisation [[ LetGen]].''
    14  ''As a result we have closed dozens of open type inference bugs, especially related to GADTs and type families.''
    1657 * '''Simon Marlow: Any update?''' Previous entry: ''In joint work with Phil Trinder and his colleagues at Herriot Watt, Simon M designed implemented a new '''parallel strategies library''', described in their 2010 Haskell Symposium paper [[ Seq]].''