[commit: ghc] master: Refactor unfoldings (6e0f6ed)

git at git.haskell.org git at git.haskell.org
Thu Aug 28 11:11:46 UTC 2014


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/6e0f6ededff6018a88dd390590a09f79842ccfa5/ghc

>---------------------------------------------------------------

commit 6e0f6ededff6018a88dd390590a09f79842ccfa5
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Thu May 8 11:21:16 2014 +0100

    Refactor unfoldings
    
    There are two main refactorings here
    
    1.  Move the uf_arity field
           out of CoreUnfolding
           into UnfWhen
        It's a lot tidier there.  If I've got this right, no behaviour
        should change.
    
    2.  Define specUnfolding and use it in DsBinds and Specialise
         a) commons-up some shared code
         b) makes sure that Specialise correctly specialises DFun
            unfoldings (which it didn't before)
    
    The two got put together because both ended up interacting in the
    specialiser.
    
    They cause zero difference to nofib.


>---------------------------------------------------------------

6e0f6ededff6018a88dd390590a09f79842ccfa5
 compiler/coreSyn/CoreSubst.lhs                     |   9 +-
 compiler/coreSyn/CoreSyn.lhs                       |  13 +-
 compiler/coreSyn/CoreUnfold.lhs                    | 307 +++++++++++++--------
 compiler/coreSyn/PprCore.lhs                       |   8 +-
 compiler/deSugar/DsBinds.lhs                       |  24 +-
 compiler/iface/MkIface.lhs                         |  10 +-
 compiler/iface/TcIface.lhs                         |   6 +-
 compiler/simplCore/Simplify.lhs                    |  10 +-
 compiler/specialise/Specialise.lhs                 |  97 ++++---
 .../tests/deSugar/should_compile/T2431.stderr      |   6 +-
 .../tests/numeric/should_compile/T7116.stdout      |  24 +-
 .../tests/simplCore/should_compile/T3717.stderr    |   6 +-
 .../tests/simplCore/should_compile/T4908.stderr    |  11 +-
 .../tests/simplCore/should_compile/T4930.stderr    |   6 +-
 .../tests/simplCore/should_compile/T7360.stderr    |  22 +-
 .../tests/simplCore/should_compile/T7785.stderr    |   2 +-
 .../tests/simplCore/should_compile/T8848.stderr    |   4 +-
 testsuite/tests/simplCore/should_compile/all.T     |   2 +-
 .../simplCore/should_compile/spec-inline.stderr    |  27 +-
 testsuite/tests/simplCore/should_run/T2486.stderr  |   8 +-
 20 files changed, 340 insertions(+), 262 deletions(-)

Diff suppressed because of size. To see it, use:

    git diff-tree --root --patch-with-stat --no-color --find-copies-harder --ignore-space-at-eol --cc 6e0f6ededff6018a88dd390590a09f79842ccfa5


More information about the ghc-commits mailing list