Commit 24e50f98 authored by Ben Gamari's avatar Ben Gamari Committed by Ben Gamari

rts: Add heap breakdown type for -hT

Test Plan: Build, program with `-eventlog`, try running with `+RTS -h`

Reviewers: austin, erikd, simonmar

Subscribers: rwbarton, thomie

GHC Trac Issues: #14096

Differential Revision: https://phabricator.haskell.org/D3922
parent 822abbb1
......@@ -687,6 +687,10 @@ All the different profile types yield a graph of live heap against time,
but they differ in how the live heap is broken down into bands. The
following RTS options select which break-down to use:
.. rts-flag:: -hT
Breaks down the graph by heap closure type.
.. rts-flag:: -hc
-h
......
......@@ -241,6 +241,7 @@ typedef enum {
HEAP_PROF_BREAKDOWN_TYPE_DESCR,
HEAP_PROF_BREAKDOWN_RETAINER,
HEAP_PROF_BREAKDOWN_BIOGRAPHY,
HEAP_PROF_BREAKDOWN_CLOSURE_TYPE,
} HeapProfBreakdown;
#if !defined(EVENTLOG_CONSTANTS_ONLY)
......
......@@ -1109,6 +1109,8 @@ static HeapProfBreakdown getHeapProfBreakdown(void)
return HEAP_PROF_BREAKDOWN_RETAINER;
case HEAP_BY_LDV:
return HEAP_PROF_BREAKDOWN_BIOGRAPHY;
case HEAP_BY_CLOSURE_TYPE:
return HEAP_PROF_BREAKDOWN_CLOSURE_TYPE;
default:
barf("getHeapProfBreakdown: unknown heap profiling mode");
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment