#698: GHC's internal memory allocator never releases memory back to the OS
---------------------------------+------------------------------------------
    Reporter:  guest             |        Owner:  igloo           
        Type:  bug               |       Status:  new             
    Priority:  low               |    Milestone:  6.12 branch     
   Component:  Runtime System    |      Version:  6.4.1           
    Severity:  normal            |   Resolution:                  
    Keywords:                    |   Difficulty:  Moderate (1 day)
    Testcase:  N/A               |           Os:  Unknown/Multiple
Architecture:  Unknown/Multiple  |  
---------------------------------+------------------------------------------
Comment (by crutcher):

 I want to work on this.

 It seems that there's little agreement on what the 'right' behavior is,
 because there are many different execution models for which different
 behaviors are preferable. It seems we need a means of setting a memory
 reclamation policy, and plugging in some number of implementations of that
 policy, with flags to set it.

 Off the top of my head, I see a few obvious ones:
    * Never return free memory (the current behavior)
    * Immediately return free memory (the notional behavior)
    * Return outstanding free memory on 'flush' events (nice for the dll
 case?)
    * Fixed Buffer - return free memory over X, for some buffer size X.
    * Ratio Buffer - return free memory over R, for some ratio of used
 memory.

 And there's this one, which I'd like to be able to play with, but has
 numerous knobs.
    * Derivative Ratio Buffer - at time t, estimate the derivative D(t) of
 memory use, and return free memory over R*D(t+h) for some ration R and
 time step h.

 Thoughts?

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/698#comment:17>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to