summaryrefslogtreecommitdiff
path: root/rts/eventlog/EventLog.h
diff options
context:
space:
mode:
authorDuncan Coutts <duncan@well-typed.com>2012-02-22 18:25:27 +0000
committerDuncan Coutts <duncan@well-typed.com>2012-04-04 19:10:45 +0100
commit1f809ce6df1dca54b977c6cac8f2b1c745683cf9 (patch)
tree889ba5ffb8c739988e552e9e9df87f6f87724606 /rts/eventlog/EventLog.h
parente88f1625a234e5316e903f84ae4d3349fec4bf3d (diff)
downloadhaskell-1f809ce6df1dca54b977c6cac8f2b1c745683cf9.tar.gz
Emit final heap alloc events and rearrange code to calculate alloc totals
In stat_exit we want to emit a final EVENT_HEAP_ALLOCATED for each cap so that we get the same total allocation count as reported via +RTS -s. To do so we need to update the per-cap total_allocated counts. Previously we had a single calcAllocated(rtsBool) function that counted the large allocations and optionally the nurseries for all caps. The GC would always call it with false, and the stat_exit always with true. The reason for these two modes is that the GC counts the nurseries via clearNurseries() (which also updates the per-cap total_allocated counts), so it's only the stat_exit() path that needs to count them. We now split the calcAllocated() function into two: countLargeAllocated and updateNurseriesStats. As the name suggests, the latter now updates the per-cap total_allocated counts, in additon to returning a total.
Diffstat (limited to 'rts/eventlog/EventLog.h')
0 files changed, 0 insertions, 0 deletions