-----------------------------------------------------------------------------
--- $Id: DriverState.hs,v 1.48 2001/07/09 17:44:08 sof Exp $
+-- $Id: DriverState.hs,v 1.51 2001/07/31 10:06:25 sewardj Exp $
--
-- Settings for the driver
--
GLOBAL_VAR(v_MaxSimplifierIterations, 4, Int)
GLOBAL_VAR(v_StgStats, False, Bool)
GLOBAL_VAR(v_UsageSPInf, False, Bool) -- Off by default
-GLOBAL_VAR(v_Strictness, True, Bool)
+GLOBAL_VAR(v_Strictness, False {-True-}, Bool)
GLOBAL_VAR(v_CPR, True, Bool)
GLOBAL_VAR(v_CSE, True, Bool)
]),
CoreDoSimplify (isAmongSimpl [
- MaxSimplifierIterations 2
+ MaxSimplifierIterations 3
-- No -finline-phase: allow all Ids to be inlined now
-- This gets foldr inlined before strictness analysis
+ --
+ -- At least 3 iterations because otherwise we land up with
+ -- huge dead expressions because of an infelicity in the
+ -- simpifier.
+ -- let k = BIG in foldr k z xs
+ -- ==> let k = BIG in letrec go = \xs -> ...(k x).... in go xs
+ -- ==> let k = BIG in letrec go = \xs -> ...(BIG x).... in go xs
+ -- Don't stop now!
]),
- if strictness then CoreDoStrictness else CoreDoNothing,
if cpr then CoreDoCPResult else CoreDoNothing,
+ if strictness then CoreDoStrictness else CoreDoNothing,
CoreDoWorkerWrapper,
CoreDoGlomBinds,