[Haskell-cafe] Parallel weirdness [new insights]

Andrew Coppin andrewcoppin at btinternet.com
Sun Apr 20 16:08:59 EDT 2008

Bulat Ziganshin wrote:
>> 3. Is there any way for a running Haskell program to find out how much
>> heap space is currently allocated / used / free?
> i think it's possible by asking internal RTS vars. SM once suggested
> to add to GHC library that provides official way to ask this info but
> no volunteer was happen :)

The RTS can spit out aggregate data just with a CLI switch (and it 
doesn't appear to affect runtime noticably). You don't even need to 
compile with profiling enabled. This seems to indicate that the data is 
easy to collect, there's just no path for accessing it yet. I'm no GHC 
developer, but from the outside it "appears" to be a fairly simple 
problem. If I knew anything about the RTS, I'd volunteer myself. But I 
suspect this is one of those jobs that requires knowledge of C... :-(

More information about the Haskell-Cafe mailing list