From 5dc8b425443200a5160b9d1399aca1808bfcffee Mon Sep 17 00:00:00 2001 From: "dias@eecs.tufts.edu" Date: Mon, 16 Mar 2009 21:35:06 +0000 Subject: stack overflows and out of memory's 1. Stack overflow fixed by making dataflow monad strict in the state. 2. Out of memory fixed by "forgetting" lastoutfacts in the dataflow monad where we should. We were creating an unnecessarily long list that grew exponentially... --- compiler/cmm/CmmSpillReload.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'compiler/cmm/CmmSpillReload.hs') diff --git a/compiler/cmm/CmmSpillReload.hs b/compiler/cmm/CmmSpillReload.hs index 085dc377db..fb6931e006 100644 --- a/compiler/cmm/CmmSpillReload.hs +++ b/compiler/cmm/CmmSpillReload.hs @@ -66,7 +66,7 @@ changeRegs f live = live { in_regs = f (in_regs live) } dualLiveLattice :: DataflowLattice DualLive dualLiveLattice = - DataflowLattice "variables live in registers and on stack" empty add False + DataflowLattice "variables live in registers and on stack" empty add True where empty = DualLive emptyRegSet emptyRegSet -- | compute in the Tx monad to track whether anything has changed add new old = do stack <- add1 (on_stack new) (on_stack old) -- cgit v1.2.1