cvs commit: fptools/ghc/compiler/coreSyn CorePrep.lhs CoreUtils.lhs
fptools/ghc/compiler/simplCore SimplUtils.lhs LiberateCase.lhs
Simon Peyton Jones
simonpj@glass.cse.ogi.edu
Wed, 3 Oct 2001 06:58:51 -0700
simonpj 2001/10/03 06:58:51 PDT
Modified files:
ghc/compiler/coreSyn CorePrep.lhs CoreUtils.lhs
ghc/compiler/simplCore SimplUtils.lhs LiberateCase.lhs
Log:
---------------------
Clear up infelicities
---------------------
CorePrep, CoreUtils, SimplUtils
LiberateCase (wibbles only)
* Previously CorePrep was floating LocalIds to top level, which
breaks the invariant that after CorePrep all top level Ids are
GlobalIds. But it didn't really need to, and this pass makes it
so. It's much tidier now.
* Make CorePrep do eta expansion on partial applications
x = foldr f y ==> x = \ys -> foldr f y ys
(This used to be done in the simplifier, but now the
simplifier only eta expands where there is at least one
lambda already.)
* Omit CoreUtils.etaReduce. (Never called.)
* Improve CoreUtils.etaExpand, so that it doesn't add gratuitous
beta redexes.
Revision Changes Path
1.9 +81 -39 fptools/ghc/compiler/coreSyn/CorePrep.lhs
1.88 +47 -67 fptools/ghc/compiler/coreSyn/CoreUtils.lhs
1.71 +3 -6 fptools/ghc/compiler/simplCore/SimplUtils.lhs
1.24 +0 -1 fptools/ghc/compiler/simplCore/LiberateCase.lhs