• Sebastian Graf's avatar
    Implement late lambda lift · b2950e03
    Sebastian Graf authored
    This implements a selective lambda-lifting pass late in the STG
    Lambda lifting has the effect of avoiding closure allocation at the cost
    of having to make former free vars available at call sites, possibly
    enlarging closures surrounding call sites in turn.
    We identify beneficial cases by means of an analysis that estimates
    closure growth.
    There's a Wiki page at
    Reviewers: simonpj, bgamari, simonmar
    Reviewed By: simonpj
    Subscribers: rwbarton, carter
    GHC Trac Issues: #9476
    Differential Revision: https://phabricator.haskell.org/D5224
Demand.hs 79.6 KB