X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Fmain%2FDriverState.hs;h=2471eb08af3354e8402f4ec12da13fa7836ec9e9;hb=4d9d0308c951ace938b5a209a8b046260739b3f1;hp=3dc7951fc73b9c8a5deb98ddb96446d11dcf576c;hpb=f4c599d2460672cdeec7e6b3c4c99bb308a54b67;p=ghc-hetmet.git diff --git a/ghc/compiler/main/DriverState.hs b/ghc/compiler/main/DriverState.hs index 3dc7951..2471eb0 100644 --- a/ghc/compiler/main/DriverState.hs +++ b/ghc/compiler/main/DriverState.hs @@ -1,5 +1,5 @@ ----------------------------------------------------------------------------- --- $Id: DriverState.hs,v 1.30 2001/02/28 11:48:34 simonpj Exp $ +-- $Id: DriverState.hs,v 1.31 2001/03/01 17:07:49 simonpj Exp $ -- -- Settings for the driver -- @@ -281,6 +281,20 @@ buildCoreToDo = do else CoreDoNothing, if opt_level >= 2 then + CoreDoSimplify (isAmongSimpl [ + MaxSimplifierIterations max_iter + -- No -finline-phase: allow all Ids to be inlined now + ]) + else + CoreDoNothing, + -- Simplify before SpecConstr, because LiberateCase leaves + -- case binders the wrong way round. E.g. it leaves it like + -- case x of wild { ... f x .... } + -- rather than + -- case x of wild { ... f wild ... } + -- The latter is better because 'wild' has the unfolding for + -- x inside it. + if opt_level >= 2 then CoreDoSpecConstr else CoreDoNothing,