[GHC] #947: ghc -O space leak: CSE between different CAFs
GHC
cvs-ghc at haskell.org
Mon Oct 15 13:37:08 CEST 2012
#947: ghc -O space leak: CSE between different CAFs
---------------------------+------------------------------------------------
Reporter: int-e@… | Owner:
Type: bug | Status: new
Priority: normal | Milestone: _|_
Component: Compiler | Version: 6.5
Resolution: | Keywords:
Os: Linux | Architecture: x86
Failure: None/Unknown | Difficulty: Unknown
Testcase: | Blockedby:
Blocking: | Related:
---------------------------+------------------------------------------------
Comment(by int-e):
Replying to [comment:9 simonpj]:
> I have one other very simple suggestion: '''do no CSE for top-level
CAFs'''.
Sounds like a great idea to me. An added benefit is that it would lend
more safety to constructing top-level mutable variables (like
{{{IORef}}}s). The loss of sharing should be negligible for most purposes,
but I can think of a few cases where giving names to shared parts would be
awkward:
* repeated string constants when doing text processing
* repeated numerical values, in particular large constants containing
repetitions (the worst of this can probably be avoided by just doing CSE
before floating stuff out so that {{{[0,1,0,1]}}} ends up with the zeros
and ones shared).
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/947#comment:10>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list