getMBlocks

Simon Marlow simonmarhaskell at gmail.com
Fri Aug 11 07:55:35 EDT 2006


Rich Fought wrote:
> 
>> Did you try GHC's heap profiler?
>>
>> Or simply running your program with +RTS -Sstderr will give you a clue 
>> about the shape of the heap usage - each line is a single GC, and it 
>> includes the amount of live data at that point.
>>
>> If your program has a flat heap profile and yet is still grabbing more 
>> memory, then something else is going on.
>>
>> Cheers,
>>     Simon
>>
> 
> Well the profile is definitely not flat.
> 
> I'm using the profiling tools and Network.accept is apparently the major 
> offender using both -hc and -hr profiles.  I take it this implies that 
> the products of this function are being retained elsewhere.  I do pass 
> the handle off to another thread via forking - this shouldn't be an 
> issue should it?  Another retainer involves SYSTEM and Network.accept - 
> what exactly does SYSTEM mean?

SYSTEM is usually the stack, or some other root maintatined by the system (eg. a 
StablePtr).

Cheers,
	Simon


More information about the Glasgow-haskell-users mailing list