diff options
author | dias@eecs.harvard.edu <unknown> | 2008-10-16 10:42:18 +0000 |
---|---|---|
committer | dias@eecs.harvard.edu <unknown> | 2008-10-16 10:42:18 +0000 |
commit | c62b824e9e8808eb3845ddb1614494b0575eaafd (patch) | |
tree | 8b28cee1e33d11741056d9dea5c5e807f62fc92f /compiler/cmm/CmmSpillReload.hs | |
parent | 41f7ea2f3c5bc25a4a910583a9b455e88e983519 (diff) | |
download | haskell-c62b824e9e8808eb3845ddb1614494b0575eaafd.tar.gz |
Fixed linear regalloc bug, dropped some tracing code
o The linear-scan register allocator sometimes allocated a block
before allocating one of its predecessors, which could lead
to inconsistent allocations. Now, we allocate a block only
if a predecessor has set the "incoming" assignments for the block
(or if it's the procedure's entry block).
o Also commented out some tracing code on the new codegen path.
Diffstat (limited to 'compiler/cmm/CmmSpillReload.hs')
-rw-r--r-- | compiler/cmm/CmmSpillReload.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/cmm/CmmSpillReload.hs b/compiler/cmm/CmmSpillReload.hs index be043fe26c..dcbde33722 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 True + DataflowLattice "variables live in registers and on stack" empty add False 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) @@ -195,7 +195,7 @@ data AvailRegs = UniverseMinus RegSet availRegsLattice :: DataflowLattice AvailRegs -availRegsLattice = DataflowLattice "register gotten from reloads" empty add True +availRegsLattice = DataflowLattice "register gotten from reloads" empty add False -- last True <==> debugging on where empty = UniverseMinus emptyRegSet -- | compute in the Tx monad to track whether anything has changed |