[GHC] #698: GHC's internal memory allocator never releases memory back to the OS

GHC trac at galois.com
Mon Feb 20 09:27:33 EST 2006


#698: GHC's internal memory allocator never releases memory back to the OS
-----------------------------+----------------------------------------------
  Reporter:  guest           |          Owner:       
      Type:  bug             |         Status:  new  
  Priority:  low             |      Milestone:       
 Component:  Runtime System  |        Version:  6.4.1
  Severity:  normal          |     Resolution:       
  Keywords:                  |             Os:  Linux
Difficulty:  Unknown         |   Architecture:  x86  
-----------------------------+----------------------------------------------
Changes (by simonmar):

  * component:  Compiler (FFI) => Runtime System
  * priority:  normal => low
  * summary:  allocaBytes does not actually free the memory after the
              computation => GHC's internal memory allocator
              never releases memory back to the OS

Comment:

 I've changed $(subject), this bug is actually just an instance of the more
 general problem that GHC never releases any memory back to the OS.  The
 memory allocated by allocaBytes has actually been "freed", but it is still
 held by GHC's memory allocator, and not the OS.

 Normally this isn't a big problem, because the memory will be re-used by
 GHC.  However, in cases where you have a large spike in memory use or want
 to temporarily allocate a very large object, it becomes noticeable.

-- 
Ticket URL: <http://cvs.haskell.org/trac/ghc/ticket/698>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the Glasgow-haskell-bugs mailing list