summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--rts/Profiling.c112
-rw-r--r--testsuite/driver/testlib.py47
-rw-r--r--testsuite/tests/profiling/should_run/T2552.prof.sample57
-rw-r--r--testsuite/tests/profiling/should_run/T5559.prof.sample33
-rw-r--r--testsuite/tests/profiling/should_run/T5654b-O0.prof.sample40
-rw-r--r--testsuite/tests/profiling/should_run/T5654b-O1.prof.sample40
-rw-r--r--testsuite/tests/profiling/should_run/T680.prof.sample65
-rw-r--r--testsuite/tests/profiling/should_run/all.T2
-rw-r--r--testsuite/tests/profiling/should_run/ioprof.prof.sample74
-rw-r--r--testsuite/tests/profiling/should_run/prof-doc-fib.prof.sample41
-rw-r--r--testsuite/tests/profiling/should_run/prof-doc-last.prof.sample54
-rw-r--r--testsuite/tests/profiling/should_run/profinline001.prof.sample39
-rw-r--r--testsuite/tests/profiling/should_run/scc001.prof.sample48
-rw-r--r--testsuite/tests/profiling/should_run/scc002.prof.sample45
-rw-r--r--testsuite/tests/profiling/should_run/scc003.prof.sample54
-rw-r--r--testsuite/tests/profiling/should_run/scc005.prof.sample35
16 files changed, 441 insertions, 345 deletions
diff --git a/rts/Profiling.c b/rts/Profiling.c
index a4fc281967..ea1e9dbb2e 100644
--- a/rts/Profiling.c
+++ b/rts/Profiling.c
@@ -119,16 +119,19 @@ static void findCCSMaxLens ( CostCentreStack *ccs,
uint32_t indent,
uint32_t *max_label_len,
uint32_t *max_module_len,
+ uint32_t *max_src_len,
uint32_t *max_id_len );
static void logCCS ( CostCentreStack *ccs,
uint32_t indent,
uint32_t max_label_len,
uint32_t max_module_len,
+ uint32_t max_src_len,
uint32_t max_id_len );
static void reportCCS ( CostCentreStack *ccs );
static CostCentreStack * checkLoop ( CostCentreStack *ccs,
CostCentre *cc );
static CostCentreStack * pruneCCSTree ( CostCentreStack *ccs );
+static void sortCCSTree ( CostCentreStack *ccs );
static CostCentreStack * actualPush ( CostCentreStack *, CostCentre * );
static CostCentreStack * isInIndexTable ( IndexTable *, CostCentre * );
static IndexTable * addToIndexTable ( IndexTable *, CostCentreStack *,
@@ -764,13 +767,14 @@ static void
reportPerCCCosts( void )
{
CostCentre *cc, *next;
- uint32_t max_label_len, max_module_len;
+ uint32_t max_label_len, max_module_len, max_src_len;
aggregateCCCosts(CCS_MAIN);
sorted_cc_list = NULL;
max_label_len = 11; // no shorter than the "COST CENTRE" header
max_module_len = 6; // no shorter than the "MODULE" header
+ max_src_len = 3; // no shorter than the "SRC" header
for (cc = CC_LIST; cc != NULL; cc = next) {
next = cc->link;
@@ -781,10 +785,12 @@ reportPerCCCosts( void )
max_label_len = stg_max(strlen_utf8(cc->label), max_label_len);
max_module_len = stg_max(strlen_utf8(cc->module), max_module_len);
+ max_src_len = stg_max(strlen_utf8(cc->srcloc), max_src_len);
}
}
- fprintf(prof_file, "%-*s %-*s", max_label_len, "COST CENTRE", max_module_len, "MODULE");
+ fprintf(prof_file, "%-*s %-*s %-*s",
+ max_label_len, "COST CENTRE", max_module_len, "MODULE", max_src_len, "SRC");
fprintf(prof_file, " %6s %6s", "%time", "%alloc");
if (RtsFlags.CcFlags.doCostCentres >= COST_CENTRES_VERBOSE) {
fprintf(prof_file, " %5s %9s", "ticks", "bytes");
@@ -795,11 +801,13 @@ reportPerCCCosts( void )
if (ignoreCC(cc)) {
continue;
}
- fprintf(prof_file, "%s%*s %s%*s",
+ fprintf(prof_file, "%s%*s %s%*s %s%*s",
cc->label,
max_label_len - strlen_utf8(cc->label), "",
cc->module,
- max_module_len - strlen_utf8(cc->module), "");
+ max_module_len - strlen_utf8(cc->module), "",
+ cc->srcloc,
+ max_src_len - strlen_utf8(cc->srcloc), "");
fprintf(prof_file, " %6.1f %6.1f",
total_prof_ticks == 0 ? 0.0 : (cc->time_ticks / (StgFloat) total_prof_ticks * 100),
@@ -823,17 +831,19 @@ reportPerCCCosts( void )
static void
fprintHeader( uint32_t max_label_len, uint32_t max_module_len,
- uint32_t max_id_len )
+ uint32_t max_src_len, uint32_t max_id_len )
{
- fprintf(prof_file, "%-*s %-*s %-*s %11s %12s %12s\n",
+ fprintf(prof_file, "%-*s %-*s %-*s %-*s %11s %12s %12s\n",
max_label_len, "",
max_module_len, "",
+ max_src_len, "",
max_id_len, "",
"", "individual", "inherited");
- fprintf(prof_file, "%-*s %-*s %-*s",
+ fprintf(prof_file, "%-*s %-*s %-*s %-*s",
max_label_len, "COST CENTRE",
max_module_len, "MODULE",
+ max_src_len, "SRC",
max_id_len, "no.");
fprintf(prof_file, " %11s %5s %6s %5s %6s",
@@ -890,7 +900,9 @@ reportCCSProfiling( void )
inheritCosts(CCS_MAIN);
- reportCCS(pruneCCSTree(CCS_MAIN));
+ CostCentreStack *stack = pruneCCSTree(CCS_MAIN);
+ sortCCSTree(stack);
+ reportCCS(stack);
}
static uint32_t
@@ -911,7 +923,7 @@ numDigits(StgInt i) {
static void
findCCSMaxLens(CostCentreStack *ccs, uint32_t indent, uint32_t *max_label_len,
- uint32_t *max_module_len, uint32_t *max_id_len) {
+ uint32_t *max_module_len, uint32_t *max_src_len, uint32_t *max_id_len) {
CostCentre *cc;
IndexTable *i;
@@ -919,19 +931,21 @@ findCCSMaxLens(CostCentreStack *ccs, uint32_t indent, uint32_t *max_label_len,
*max_label_len = stg_max(*max_label_len, indent + strlen_utf8(cc->label));
*max_module_len = stg_max(*max_module_len, strlen_utf8(cc->module));
+ *max_src_len = stg_max(*max_src_len, strlen_utf8(cc->srcloc));
*max_id_len = stg_max(*max_id_len, numDigits(ccs->ccsID));
for (i = ccs->indexTable; i != 0; i = i->next) {
if (!i->back_edge) {
findCCSMaxLens(i->ccs, indent+1,
- max_label_len, max_module_len, max_id_len);
+ max_label_len, max_module_len, max_src_len, max_id_len);
}
}
}
static void
logCCS(CostCentreStack *ccs, uint32_t indent,
- uint32_t max_label_len, uint32_t max_module_len, uint32_t max_id_len)
+ uint32_t max_label_len, uint32_t max_module_len,
+ uint32_t max_src_len, uint32_t max_id_len)
{
CostCentre *cc;
IndexTable *i;
@@ -944,12 +958,14 @@ logCCS(CostCentreStack *ccs, uint32_t indent,
/* force printing of *all* cost centres if -Pa */
{
- fprintf(prof_file, "%-*s%s%*s %s%*s",
+ fprintf(prof_file, "%*s%s%*s %s%*s %s%*s",
indent, "",
cc->label,
max_label_len-indent - strlen_utf8(cc->label), "",
cc->module,
- max_module_len - strlen_utf8(cc->module), "");
+ max_module_len - strlen_utf8(cc->module), "",
+ cc->srcloc,
+ max_src_len - strlen_utf8(cc->srcloc), "");
fprintf(prof_file,
" %*" FMT_Int "%11" FMT_Word64 " %5.1f %5.1f %5.1f %5.1f",
@@ -969,7 +985,8 @@ logCCS(CostCentreStack *ccs, uint32_t indent,
for (i = ccs->indexTable; i != 0; i = i->next) {
if (!i->back_edge) {
- logCCS(i->ccs, indent+1, max_label_len, max_module_len, max_id_len);
+ logCCS(i->ccs, indent+1,
+ max_label_len, max_module_len, max_src_len, max_id_len);
}
}
}
@@ -977,16 +994,18 @@ logCCS(CostCentreStack *ccs, uint32_t indent,
static void
reportCCS(CostCentreStack *ccs)
{
- uint32_t max_label_len, max_module_len, max_id_len;
+ uint32_t max_label_len, max_module_len, max_src_len, max_id_len;
max_label_len = 11; // no shorter than "COST CENTRE" header
max_module_len = 6; // no shorter than "MODULE" header
+ max_src_len = 3; // no shorter than "SRC" header
max_id_len = 3; // no shorter than "no." header
- findCCSMaxLens(ccs, 0, &max_label_len, &max_module_len, &max_id_len);
+ findCCSMaxLens(ccs, 0,
+ &max_label_len, &max_module_len, &max_src_len, &max_id_len);
- fprintHeader(max_label_len, max_module_len, max_id_len);
- logCCS(ccs, 0, max_label_len, max_module_len, max_id_len);
+ fprintHeader(max_label_len, max_module_len, max_src_len, max_id_len);
+ logCCS(ccs, 0, max_label_len, max_module_len, max_src_len, max_id_len);
}
@@ -1064,6 +1083,63 @@ pruneCCSTree (CostCentreStack *ccs)
}
}
+static IndexTable*
+insertIndexTableInSortedList(IndexTable* tbl, IndexTable* sortedList)
+{
+ StgWord tbl_ticks = tbl->ccs->scc_count;
+ char* tbl_label = tbl->ccs->cc->label;
+
+ IndexTable *prev = NULL;
+ IndexTable *cursor = sortedList;
+
+ while (cursor != NULL) {
+ StgWord cursor_ticks = cursor->ccs->scc_count;
+ char* cursor_label = cursor->ccs->cc->label;
+
+ if (tbl_ticks > cursor_ticks ||
+ (tbl_ticks == cursor_ticks && strcmp(tbl_label, cursor_label) < 0)) {
+ if (prev == NULL) {
+ tbl->next = sortedList;
+ return tbl;
+ } else {
+ prev->next = tbl;
+ tbl->next = cursor;
+ return sortedList;
+ }
+ } else {
+ prev = cursor;
+ cursor = cursor->next;
+ }
+ }
+
+ prev->next = tbl;
+ return sortedList;
+}
+
+static void
+sortCCSTree(CostCentreStack *ccs)
+{
+ if (ccs->indexTable == NULL) return;
+
+ for (IndexTable *tbl = ccs->indexTable; tbl != NULL; tbl = tbl->next)
+ if (!tbl->back_edge)
+ sortCCSTree(tbl->ccs);
+
+ IndexTable *sortedList = ccs->indexTable;
+ IndexTable *nonSortedList = sortedList->next;
+ sortedList->next = NULL;
+
+ while (nonSortedList != NULL)
+ {
+ IndexTable *nonSortedTail = nonSortedList->next;
+ nonSortedList->next = NULL;
+ sortedList = insertIndexTableInSortedList(nonSortedList, sortedList);
+ nonSortedList = nonSortedTail;
+ }
+
+ ccs->indexTable = sortedList;
+}
+
void
fprintCCS( FILE *f, CostCentreStack *ccs )
{
diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py
index 53f342371e..fb93721ae3 100644
--- a/testsuite/driver/testlib.py
+++ b/testsuite/driver/testlib.py
@@ -1763,21 +1763,38 @@ def normalise_prof (str):
str = re.sub('[ \t]*main[ \t]+Main.*\n','',str)
# We have somthing like this:
-
- # MAIN MAIN 101 0 0.0 0.0 100.0 100.0
- # k Main 204 1 0.0 0.0 0.0 0.0
- # foo Main 205 1 0.0 0.0 0.0 0.0
- # foo.bar Main 207 1 0.0 0.0 0.0 0.0
-
- # then we remove all the specific profiling data, leaving only the
- # cost centre name, module, and entries, to end up with this:
-
- # MAIN MAIN 0
- # k Main 1
- # foo Main 1
- # foo.bar Main 1
-
- str = re.sub('\n([ \t]*[^ \t]+)([ \t]+[^ \t]+)([ \t]+\\d+)([ \t]+\\d+)[ \t]+([\\d\\.]+)[ \t]+([\\d\\.]+)[ \t]+([\\d\\.]+)[ \t]+([\\d\\.]+)','\n\\1 \\2 \\4',str)
+ #
+ # MAIN MAIN <built-in> 53 0 0.0 0.2 0.0 100.0
+ # CAF Main <entire-module> 105 0 0.0 0.3 0.0 62.5
+ # readPrec Main Main_1.hs:7:13-16 109 1 0.0 0.6 0.0 0.6
+ # readPrec Main Main_1.hs:4:13-16 107 1 0.0 0.6 0.0 0.6
+ # main Main Main_1.hs:(10,1)-(20,20) 106 1 0.0 20.2 0.0 61.0
+ # == Main Main_1.hs:7:25-26 114 1 0.0 0.0 0.0 0.0
+ # == Main Main_1.hs:4:25-26 113 1 0.0 0.0 0.0 0.0
+ # showsPrec Main Main_1.hs:7:19-22 112 2 0.0 1.2 0.0 1.2
+ # showsPrec Main Main_1.hs:4:19-22 111 2 0.0 0.9 0.0 0.9
+ # readPrec Main Main_1.hs:7:13-16 110 0 0.0 18.8 0.0 18.8
+ # readPrec Main Main_1.hs:4:13-16 108 0 0.0 19.9 0.0 19.9
+ #
+ # then we remove all the specific profiling data, leaving only the cost
+ # centre name, module, src, and entries, to end up with this: (modulo
+ # whitespace between columns)
+ #
+ # MAIN MAIN <built-in> 0
+ # readPrec Main Main_1.hs:7:13-16 1
+ # readPrec Main Main_1.hs:4:13-16 1
+ # == Main Main_1.hs:7:25-26 1
+ # == Main Main_1.hs:4:25-26 1
+ # showsPrec Main Main_1.hs:7:19-22 2
+ # showsPrec Main Main_1.hs:4:19-22 2
+ # readPrec Main Main_1.hs:7:13-16 0
+ # readPrec Main Main_1.hs:4:13-16 0
+
+ # Split 9 whitespace-separated groups, take columns 1 (cost-centre), 2
+ # (module), 3 (src), and 5 (entries). SCC names can't have whitespace, so
+ # this works fine.
+ str = re.sub(r'\s*(\S+)\s*(\S+)\s*(\S+)\s*(\S+)\s*(\S+)\s*(\S+)\s*(\S+)\s*(\S+)\s*(\S+)\s*',
+ '\\1 \\2 \\3 \\5\n', str)
return str
def normalise_slashes_( str ):
diff --git a/testsuite/tests/profiling/should_run/T2552.prof.sample b/testsuite/tests/profiling/should_run/T2552.prof.sample
index 3eea44a48d..7ed927f6db 100644
--- a/testsuite/tests/profiling/should_run/T2552.prof.sample
+++ b/testsuite/tests/profiling/should_run/T2552.prof.sample
@@ -1,37 +1,36 @@
- Wed Jan 27 08:12 2016 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
T2552 +RTS -hc -p -RTS
- total time = 0.01 secs (5 ticks @ 1000 us, 1 processor)
- total alloc = 123,466,024 bytes (excludes profiling overheads)
+ total time = 0.09 secs (90 ticks @ 1000 us, 1 processor)
+ total alloc = 123,465,848 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-fib1.fib1'.nfib Main 80.0 33.3
-MAIN MAIN 20.0 0.0
-fib2'.nfib Main 0.0 33.3
-fib3'.nfib Main 0.0 33.3
+fib1.fib1'.nfib Main T2552.hs:5:9-61 37.8 33.3
+fib2'.nfib Main T2552.hs:10:5-57 31.1 33.3
+fib3'.nfib Main T2552.hs:15:5-57 31.1 33.3
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 105 0 20.0 0.0 100.0 100.0
- main Main 211 0 0.0 0.0 0.0 0.0
- CAF Main 209 0 0.0 0.0 80.0 100.0
- main Main 210 1 0.0 0.0 80.0 100.0
- fib3' Main 220 1 0.0 0.0 0.0 33.3
- fib3'.nfib Main 221 1028457 0.0 33.3 0.0 33.3
- fib3 Main 219 1 0.0 0.0 0.0 0.0
- fib2 Main 216 1 0.0 0.0 0.0 33.3
- fib2' Main 217 1 0.0 0.0 0.0 33.3
- fib2'.nfib Main 218 1028457 0.0 33.3 0.0 33.3
- fib1 Main 212 1 0.0 0.0 80.0 33.3
- fib1.fib1' Main 213 1 0.0 0.0 80.0 33.3
- nfib' Main 214 1 0.0 0.0 80.0 33.3
- fib1.fib1'.nfib Main 215 1028457 80.0 33.3 80.0 33.3
- CAF GHC.Conc.Signal 203 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding 193 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding.Iconv 191 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.FD 183 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.Text 181 0 0.0 0.0 0.0 0.0
+MAIN MAIN <built-in> 45 0 0.0 0.0 100.0 100.0
+ CAF Main <entire-module> 89 0 0.0 0.0 100.0 100.0
+ main Main T2552.hs:(17,1)-(20,17) 90 1 0.0 0.0 100.0 100.0
+ fib1 Main T2552.hs:(1,1)-(5,61) 92 1 0.0 0.0 37.8 33.3
+ fib1.fib1' Main T2552.hs:(3,5)-(5,61) 93 1 0.0 0.0 37.8 33.3
+ nfib' Main T2552.hs:3:35-40 94 1 0.0 0.0 37.8 33.3
+ fib1.fib1'.nfib Main T2552.hs:5:9-61 95 1028457 37.8 33.3 37.8 33.3
+ fib2 Main T2552.hs:7:1-16 96 1 0.0 0.0 31.1 33.3
+ fib2' Main T2552.hs:(8,1)-(10,57) 97 1 0.0 0.0 31.1 33.3
+ fib2'.nfib Main T2552.hs:10:5-57 98 1028457 31.1 33.3 31.1 33.3
+ fib3 Main T2552.hs:12:1-12 99 1 0.0 0.0 0.0 0.0
+ fib3' Main T2552.hs:(13,1)-(15,57) 100 1 0.0 0.0 31.1 33.3
+ fib3'.nfib Main T2552.hs:15:5-57 101 1028457 31.1 33.3 31.1 33.3
+ CAF GHC.IO.Handle.FD <entire-module> 84 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Handle.Text <entire-module> 83 0 0.0 0.0 0.0 0.0
+ CAF GHC.Conc.Signal <entire-module> 81 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding <entire-module> 78 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding.Iconv <entire-module> 64 0 0.0 0.0 0.0 0.0
+ main Main T2552.hs:(17,1)-(20,17) 91 0 0.0 0.0 0.0 0.0
diff --git a/testsuite/tests/profiling/should_run/T5559.prof.sample b/testsuite/tests/profiling/should_run/T5559.prof.sample
index 5c4b74a0fa..ac72ae5c34 100644
--- a/testsuite/tests/profiling/should_run/T5559.prof.sample
+++ b/testsuite/tests/profiling/should_run/T5559.prof.sample
@@ -1,25 +1,24 @@
- Thu Apr 2 19:44 2015 Time and Allocation Profiling Report (Final)
+ Fri Jun 3 10:46 2016 Time and Allocation Profiling Report (Final)
T5559 +RTS -p -RTS
- total time = 0.04 secs (36 ticks @ 1000 us, 1 processor)
- total alloc = 57,359,016 bytes (excludes profiling overheads)
+ total time = 0.04 secs (39 ticks @ 1000 us, 1 processor)
+ total alloc = 57,359,352 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-føb Main 97.2 99.9
-MAIN MAIN 2.8 0.0
+føb Main T5559.hs:(2,1)-(5,38) 100.0 99.9
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 99 0 2.8 0.0 100.0 100.0
- CAF Main 197 0 0.0 0.0 97.2 99.9
- main Main 198 1 0.0 0.0 97.2 99.9
- føb Main 199 392835 97.2 99.9 97.2 99.9
- CAF GHC.Conc.Signal 179 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding 163 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding.Iconv 161 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.FD 152 0 0.0 0.1 0.0 0.1
- CAF GHC.IO.Handle.Text 150 0 0.0 0.0 0.0 0.0
+MAIN MAIN <built-in> 45 0 0.0 0.0 100.0 100.0
+ CAF Main <entire-module> 89 0 0.0 0.0 100.0 99.9
+ main Main T5559.hs:8:1-21 90 1 0.0 0.0 100.0 99.9
+ føb Main T5559.hs:(2,1)-(5,38) 91 392835 100.0 99.9 100.0 99.9
+ CAF GHC.Conc.Signal <entire-module> 80 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding <entire-module> 77 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Handle.FD <entire-module> 75 0 0.0 0.1 0.0 0.1
+ CAF GHC.IO.Handle.Text <entire-module> 73 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding.Iconv <entire-module> 56 0 0.0 0.0 0.0 0.0
diff --git a/testsuite/tests/profiling/should_run/T5654b-O0.prof.sample b/testsuite/tests/profiling/should_run/T5654b-O0.prof.sample
index f98fcf0cbf..b803917865 100644
--- a/testsuite/tests/profiling/should_run/T5654b-O0.prof.sample
+++ b/testsuite/tests/profiling/should_run/T5654b-O0.prof.sample
@@ -1,29 +1,29 @@
- Wed Jan 27 08:16 2016 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
T5654b-O0 +RTS -p -RTS
total time = 0.00 secs (0 ticks @ 1000 us, 1 processor)
- total alloc = 39,248 bytes (excludes profiling overheads)
+ total alloc = 39,112 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-CAF GHC.IO.Handle.FD 0.0 88.0
-CAF GHC.IO.Encoding 0.0 7.3
-CAF GHC.Conc.Signal 0.0 1.7
+CAF GHC.IO.Handle.FD <entire-module> 0.0 88.2
+CAF GHC.IO.Encoding <entire-module> 0.0 7.1
+CAF GHC.Conc.Signal <entire-module> 0.0 1.7
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 105 0 0.0 0.9 0.0 100.0
- CAF Main 209 0 0.0 0.9 0.0 1.5
- g Main 212 1 0.0 0.1 0.0 0.1
- f Main 211 1 0.0 0.1 0.0 0.1
- main Main 210 1 0.0 0.2 0.0 0.4
- f Main 214 0 0.0 0.0 0.0 0.2
- g Main 215 0 0.0 0.0 0.0 0.2
- h Main 216 1 0.0 0.2 0.0 0.2
- CAF GHC.Conc.Signal 203 0 0.0 1.7 0.0 1.7
- CAF GHC.IO.Encoding 193 0 0.0 7.3 0.0 7.3
- CAF GHC.IO.Encoding.Iconv 191 0 0.0 0.6 0.0 0.6
- CAF GHC.IO.Handle.FD 183 0 0.0 88.0 0.0 88.0
+MAIN MAIN <built-in> 43 0 0.0 0.9 0.0 100.0
+ CAF Main <entire-module> 85 0 0.0 0.9 0.0 1.5
+ f Main T5654b-O0.hs:12:1-7 87 1 0.0 0.1 0.0 0.1
+ g Main T5654b-O0.hs:16:1-7 88 1 0.0 0.1 0.0 0.1
+ main Main T5654b-O0.hs:22:1-21 86 1 0.0 0.2 0.0 0.4
+ f Main T5654b-O0.hs:12:1-7 90 0 0.0 0.0 0.0 0.2
+ g Main T5654b-O0.hs:16:1-7 91 0 0.0 0.0 0.0 0.2
+ h Main T5654b-O0.hs:20:1-19 92 1 0.0 0.2 0.0 0.2
+ CAF GHC.Conc.Signal <entire-module> 77 0 0.0 1.7 0.0 1.7
+ CAF GHC.IO.Encoding <entire-module> 74 0 0.0 7.1 0.0 7.1
+ CAF GHC.IO.Handle.FD <entire-module> 72 0 0.0 88.2 0.0 88.2
+ CAF GHC.IO.Encoding.Iconv <entire-module> 54 0 0.0 0.6 0.0 0.6
diff --git a/testsuite/tests/profiling/should_run/T5654b-O1.prof.sample b/testsuite/tests/profiling/should_run/T5654b-O1.prof.sample
index 317e492dbd..45ae0ba55c 100644
--- a/testsuite/tests/profiling/should_run/T5654b-O1.prof.sample
+++ b/testsuite/tests/profiling/should_run/T5654b-O1.prof.sample
@@ -1,28 +1,28 @@
- Wed Jan 27 08:16 2016 Time and Allocation Profiling Report (Final)
+ Fri Jun 3 11:00 2016 Time and Allocation Profiling Report (Final)
- T5654b-O1 +RTS -p -RTS
+ T5654b-O1 +RTS -hc -p -RTS
total time = 0.00 secs (0 ticks @ 1000 us, 1 processor)
- total alloc = 39,016 bytes (excludes profiling overheads)
+ total alloc = 38,880 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-MAIN MAIN 0.0 1.7
-CAF GHC.IO.Handle.FD 0.0 88.5
-CAF GHC.IO.Encoding 0.0 7.4
-CAF GHC.Conc.Signal 0.0 1.7
+MAIN MAIN <built-in> 0.0 1.7
+CAF GHC.IO.Handle.FD <entire-module> 0.0 88.8
+CAF GHC.IO.Encoding <entire-module> 0.0 7.1
+CAF GHC.Conc.Signal <entire-module> 0.0 1.7
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 105 0 0.0 1.7 0.0 100.0
- CAF Main 209 0 0.0 0.0 0.0 0.1
- main Main 210 1 0.0 0.1 0.0 0.1
- f Main 211 1 0.0 0.0 0.0 0.0
- g Main 212 1 0.0 0.0 0.0 0.0
- h Main 213 1 0.0 0.0 0.0 0.0
- CAF GHC.Conc.Signal 203 0 0.0 1.7 0.0 1.7
- CAF GHC.IO.Encoding 193 0 0.0 7.4 0.0 7.4
- CAF GHC.IO.Encoding.Iconv 191 0 0.0 0.6 0.0 0.6
- CAF GHC.IO.Handle.FD 183 0 0.0 88.5 0.0 88.5
+MAIN MAIN <built-in> 43 0 0.0 1.7 0.0 100.0
+ CAF Main <entire-module> 85 0 0.0 0.0 0.0 0.1
+ main Main T5654b-O1.hs:22:1-21 86 1 0.0 0.1 0.0 0.1
+ f Main T5654b-O1.hs:12:1-7 87 1 0.0 0.0 0.0 0.0
+ g Main T5654b-O1.hs:16:1-7 88 1 0.0 0.0 0.0 0.0
+ h Main T5654b-O1.hs:20:1-19 89 1 0.0 0.0 0.0 0.0
+ CAF GHC.Conc.Signal <entire-module> 79 0 0.0 1.7 0.0 1.7
+ CAF GHC.IO.Encoding <entire-module> 74 0 0.0 7.1 0.0 7.1
+ CAF GHC.IO.Handle.FD <entire-module> 72 0 0.0 88.8 0.0 88.8
+ CAF GHC.IO.Encoding.Iconv <entire-module> 53 0 0.0 0.6 0.0 0.6
diff --git a/testsuite/tests/profiling/should_run/T680.prof.sample b/testsuite/tests/profiling/should_run/T680.prof.sample
index 6b2d037627..d14bad9bdd 100644
--- a/testsuite/tests/profiling/should_run/T680.prof.sample
+++ b/testsuite/tests/profiling/should_run/T680.prof.sample
@@ -1,37 +1,42 @@
- Thu Apr 2 19:44 2015 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
- T680 +RTS -p -RTS
+ T680 +RTS -hc -p -RTS
- total time = 0.20 secs (203 ticks @ 1000 us, 1 processor)
- total alloc = 449,665,336 bytes (excludes profiling overheads)
+ total time = 0.00 secs (0 ticks @ 1000 us, 1 processor)
+ total alloc = 752,952 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-foo.\ Main 100.0 99.8
+CAF GHC.IO.Handle.FD <entire-module> 0.0 4.6
+main Main T680.hs:20:1-14 0.0 1.2
+foo.\ Main T680.hs:3:12-40 0.0 25.5
+foo.bar Main T680.hs:(5,3)-(9,38) 0.0 29.8
+foo.bar.\ Main T680.hs:(8,11)-(9,38) 0.0 38.2
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 103 0 0.0 0.0 100.0 100.0
- CAF Main 205 0 0.0 0.0 100.0 100.0
- k Main 208 1 0.0 0.0 0.0 0.0
- foo Main 209 1 0.0 0.0 0.0 0.0
- foo.bar Main 213 1 0.0 0.0 0.0 0.0
- foo.bar.k' Main 217 1 0.0 0.0 0.0 0.0
- k.\ Main 218 1 0.0 0.0 0.0 0.0
- r Main 207 1 0.0 0.0 100.0 100.0
- k Main 210 0 0.0 0.0 100.0 100.0
- foo Main 211 0 0.0 0.0 100.0 100.0
- foo.bar Main 214 0 0.0 0.0 0.0 0.1
- foo.bar.k' Main 219 0 0.0 0.0 0.0 0.0
- foo.bar.\ Main 215 4001 0.0 0.1 0.0 0.1
- foo.bar.\.k'' Main 216 4000 0.0 0.0 0.0 0.0
- foo.\ Main 212 4001 100.0 99.8 100.0 99.8
- main Main 206 1 0.0 0.0 0.0 0.0
- CAF GHC.Conc.Signal 184 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding 167 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding.Iconv 165 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.FD 156 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.Text 154 0 0.0 0.0 0.0 0.0
- CAF GHC.Show 141 0 0.0 0.0 0.0 0.0
+MAIN MAIN <built-in> 46 0 0.0 0.1 0.0 100.0
+ CAF Main <entire-module> 91 0 0.0 0.0 0.0 93.6
+ k Main T680.hs:12:1-17 95 1 0.0 0.0 0.0 0.0
+ foo Main T680.hs:(2,1)-(9,38) 96 1 0.0 0.0 0.0 0.0
+ foo.bar Main T680.hs:(5,3)-(9,38) 100 1 0.0 0.0 0.0 0.0
+ foo.bar.k' Main T680.hs:6:9-34 104 1 0.0 0.0 0.0 0.0
+ k.\ Main T680.hs:12:16 105 1 0.0 0.0 0.0 0.0
+ main Main T680.hs:20:1-14 92 1 0.0 0.0 0.0 0.0
+ r Main T680.hs:18:1-26 94 1 0.0 0.0 0.0 93.5
+ k Main T680.hs:12:1-17 97 0 0.0 0.0 0.0 93.5
+ foo Main T680.hs:(2,1)-(9,38) 98 0 0.0 0.0 0.0 93.5
+ foo.\ Main T680.hs:3:12-40 99 4001 0.0 25.5 0.0 25.5
+ foo.bar Main T680.hs:(5,3)-(9,38) 101 0 0.0 29.8 0.0 68.0
+ foo.bar.\ Main T680.hs:(8,11)-(9,38) 102 4001 0.0 38.2 0.0 38.2
+ foo.bar.\.k'' Main T680.hs:8:15-27 103 4000 0.0 0.0 0.0 0.0
+ foo.bar.k' Main T680.hs:6:9-34 106 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Handle.FD <entire-module> 84 0 0.0 4.6 0.0 4.6
+ CAF GHC.IO.Handle.Text <entire-module> 83 0 0.0 0.0 0.0 0.0
+ CAF GHC.Conc.Signal <entire-module> 80 0 0.0 0.1 0.0 0.1
+ CAF GHC.IO.Encoding <entire-module> 78 0 0.0 0.4 0.0 0.4
+ CAF GHC.Show <entire-module> 76 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding.Iconv <entire-module> 62 0 0.0 0.0 0.0 0.0
+ main Main T680.hs:20:1-14 93 0 0.0 1.2 0.0 1.2
diff --git a/testsuite/tests/profiling/should_run/all.T b/testsuite/tests/profiling/should_run/all.T
index a12a0432ac..f3ea9b160c 100644
--- a/testsuite/tests/profiling/should_run/all.T
+++ b/testsuite/tests/profiling/should_run/all.T
@@ -39,7 +39,7 @@ test('T3001-2', [only_ways(['prof_hb']), extra_ways(['prof_hb'])],
# As with ioprof001, the unoptimised profile is different but
# not badly wrong (CAF attribution is different).
-test('scc001', [expect_broken_for_10037], compile_and_run,
+test('scc001', [], compile_and_run,
['-fno-state-hack -fno-full-laziness']) # Note [consistent stacks]
test('scc002', [], compile_and_run, [''])
diff --git a/testsuite/tests/profiling/should_run/ioprof.prof.sample b/testsuite/tests/profiling/should_run/ioprof.prof.sample
index 98f48fdadc..52ab8ba4d2 100644
--- a/testsuite/tests/profiling/should_run/ioprof.prof.sample
+++ b/testsuite/tests/profiling/should_run/ioprof.prof.sample
@@ -1,46 +1,46 @@
- Fri Oct 30 17:14 2015 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
ioprof +RTS -hc -p -RTS
total time = 0.00 secs (0 ticks @ 1000 us, 1 processor)
- total alloc = 63,680 bytes (excludes profiling overheads)
+ total alloc = 180,024 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-CAF GHC.IO.Handle.FD 0.0 54.2
-CAF GHC.IO.Encoding 0.0 5.2
-CAF GHC.Exception 0.0 1.2
-CAF GHC.Conc.Signal 0.0 1.0
-main Main 0.0 13.6
-errorM.\ Main 0.0 19.8
-CAF Main 0.0 2.6
+CAF GHC.IO.Encoding <entire-module> 0.0 1.8
+CAF GHC.IO.Handle.FD <entire-module> 0.0 19.2
+CAF GHC.Exception <entire-module> 0.0 2.5
+main Main ioprof.hs:28:1-43 0.0 4.8
+errorM.\ Main ioprof.hs:23:22-28 0.0 68.7
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 102 0 0.0 1.0 0.0 100.0
- main Main 205 0 0.0 13.5 0.0 13.5
- CAF Main 203 0 0.0 2.6 0.0 23.2
- fmap Main 212 1 0.0 0.0 0.0 0.0
- <*> Main 208 1 0.0 0.0 0.0 0.0
- main Main 204 1 0.0 0.2 0.0 20.6
- runM Main 206 1 0.0 0.3 0.0 20.4
- bar Main 207 1 0.0 0.2 0.0 20.1
- foo Main 216 1 0.0 0.0 0.0 0.0
- errorM Main 217 1 0.0 0.0 0.0 0.0
- fmap Main 213 0 0.0 0.0 0.0 0.0
- >>= Main 214 1 0.0 0.0 0.0 0.0
- <*> Main 209 0 0.0 0.0 0.0 19.8
- >>= Main 210 1 0.0 0.0 0.0 19.8
- >>=.\ Main 211 2 0.0 0.0 0.0 19.8
- foo Main 218 0 0.0 0.0 0.0 19.8
- errorM Main 219 0 0.0 0.0 0.0 19.8
- errorM.\ Main 220 1 0.0 19.8 0.0 19.8
- fmap Main 215 0 0.0 0.0 0.0 0.0
- CAF GHC.Conc.Signal 197 0 0.0 1.0 0.0 1.0
- CAF GHC.Conc.Sync 196 0 0.0 0.4 0.0 0.4
- CAF GHC.Exception 194 0 0.0 1.2 0.0 1.2
- CAF GHC.IO.Encoding 187 0 0.0 5.2 0.0 5.2
- CAF GHC.IO.Encoding.Iconv 185 0 0.0 0.4 0.0 0.4
- CAF GHC.IO.Handle.FD 177 0 0.0 54.2 0.0 54.2
+MAIN MAIN <built-in> 46 0 0.0 0.4 0.0 100.0
+ CAF Main <entire-module> 91 0 0.0 0.9 0.0 69.8
+ <*> Main ioprof.hs:20:5-14 96 1 0.0 0.0 0.0 0.0
+ fmap Main ioprof.hs:16:5-16 100 1 0.0 0.0 0.0 0.0
+ main Main ioprof.hs:28:1-43 92 1 0.0 0.0 0.0 68.9
+ runM Main ioprof.hs:26:1-37 94 1 0.0 0.1 0.0 68.9
+ bar Main ioprof.hs:31:1-20 95 1 0.0 0.1 0.0 68.8
+ foo Main ioprof.hs:34:1-16 104 1 0.0 0.0 0.0 0.0
+ errorM Main ioprof.hs:23:1-28 105 1 0.0 0.0 0.0 0.0
+ <*> Main ioprof.hs:20:5-14 97 0 0.0 0.0 0.0 68.7
+ >>= Main ioprof.hs:(11,3)-(12,50) 98 1 0.0 0.0 0.0 68.7
+ >>=.\ Main ioprof.hs:(11,27)-(12,50) 99 2 0.0 0.0 0.0 68.7
+ fmap Main ioprof.hs:16:5-16 103 0 0.0 0.0 0.0 0.0
+ foo Main ioprof.hs:34:1-16 106 0 0.0 0.0 0.0 68.7
+ errorM Main ioprof.hs:23:1-28 107 0 0.0 0.0 0.0 68.7
+ errorM.\ Main ioprof.hs:23:22-28 108 1 0.0 68.7 0.0 68.7
+ fmap Main ioprof.hs:16:5-16 101 0 0.0 0.0 0.0 0.0
+ >>= Main ioprof.hs:(11,3)-(12,50) 102 1 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Exception <entire-module> 89 0 0.0 0.7 0.0 0.7
+ CAF GHC.Exception <entire-module> 86 0 0.0 2.5 0.0 2.5
+ CAF GHC.IO.Handle.FD <entire-module> 85 0 0.0 19.2 0.0 19.2
+ CAF GHC.Conc.Signal <entire-module> 82 0 0.0 0.4 0.0 0.4
+ CAF GHC.IO.Encoding <entire-module> 80 0 0.0 1.8 0.0 1.8
+ CAF GHC.Conc.Sync <entire-module> 75 0 0.0 0.1 0.0 0.1
+ CAF GHC.Stack.CCS <entire-module> 71 0 0.0 0.2 0.0 0.2
+ CAF GHC.IO.Encoding.Iconv <entire-module> 64 0 0.0 0.1 0.0 0.1
+ main Main ioprof.hs:28:1-43 93 0 0.0 4.8 0.0 4.8
diff --git a/testsuite/tests/profiling/should_run/prof-doc-fib.prof.sample b/testsuite/tests/profiling/should_run/prof-doc-fib.prof.sample
index e35a6c746a..f680a6c3ea 100644
--- a/testsuite/tests/profiling/should_run/prof-doc-fib.prof.sample
+++ b/testsuite/tests/profiling/should_run/prof-doc-fib.prof.sample
@@ -1,27 +1,28 @@
- Thu Apr 2 19:44 2015 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
- prof-doc-fib +RTS -p -RTS
+ prof-doc-fib +RTS -hc -p -RTS
- total time = 0.31 secs (310 ticks @ 1000 us, 1 processor)
- total alloc = 538,951,032 bytes (excludes profiling overheads)
+ total time = 0.07 secs (75 ticks @ 1000 us, 1 processor)
+ total alloc = 107,829,040 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-fib Main 100.0 100.0
+fib Main prof-doc-fib.hs:9:1-50 100.0 100.0
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 99 0 0.0 0.0 100.0 100.0
- CAF Main 197 0 0.0 0.0 100.0 100.0
- main Main 198 1 0.0 0.0 100.0 100.0
- main.f Main 201 1 0.0 0.0 100.0 99.9
- fib Main 202 2692537 100.0 99.9 100.0 99.9
- main.g Main 199 1 0.0 0.0 0.0 0.1
- fib Main 200 1973 0.0 0.1 0.0 0.1
- CAF GHC.Conc.Signal 179 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding 163 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding.Iconv 161 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.FD 152 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.Text 150 0 0.0 0.0 0.0 0.0
+MAIN MAIN <built-in> 45 0 0.0 0.0 100.0 100.0
+ CAF Main <entire-module> 89 0 0.0 0.0 100.0 100.0
+ main Main prof-doc-fib.hs:(4,1)-(7,26) 90 1 0.0 0.0 100.0 100.0
+ main.f Main prof-doc-fib.hs:6:5-16 94 1 0.0 0.0 100.0 99.9
+ fib Main prof-doc-fib.hs:9:1-50 95 2692537 100.0 99.9 100.0 99.9
+ main.g Main prof-doc-fib.hs:7:5-26 92 1 0.0 0.0 0.0 0.1
+ fib Main prof-doc-fib.hs:9:1-50 93 1973 0.0 0.1 0.0 0.1
+ CAF GHC.IO.Handle.FD <entire-module> 84 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Handle.Text <entire-module> 83 0 0.0 0.0 0.0 0.0
+ CAF GHC.Conc.Signal <entire-module> 81 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding <entire-module> 78 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding.Iconv <entire-module> 64 0 0.0 0.0 0.0 0.0
+ main Main prof-doc-fib.hs:(4,1)-(7,26) 91 0 0.0 0.0 0.0 0.0
diff --git a/testsuite/tests/profiling/should_run/prof-doc-last.prof.sample b/testsuite/tests/profiling/should_run/prof-doc-last.prof.sample
index dd036490e7..371fad43d7 100644
--- a/testsuite/tests/profiling/should_run/prof-doc-last.prof.sample
+++ b/testsuite/tests/profiling/should_run/prof-doc-last.prof.sample
@@ -1,34 +1,34 @@
- Thu Apr 2 19:44 2015 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
- prof-doc-last +RTS -p -RTS
+ prof-doc-last +RTS -hc -p -RTS
- total time = 0.16 secs (160 ticks @ 1000 us, 1 processor)
- total alloc = 648,053,608 bytes (excludes profiling overheads)
+ total time = 0.12 secs (121 ticks @ 1000 us, 1 processor)
+ total alloc = 384,052,480 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-last_init_ys Main 28.1 29.6
-main.ys Main 26.2 24.7
-main.xs Main 16.9 12.3
-last_init_xs Main 14.4 14.8
-last_ys Main 7.5 12.3
-last_xs Main 6.9 6.2
+main.ys Main prof-doc-last.hs:3:15-31 39.7 37.5
+last_init_ys Main prof-doc-last.hs:7:45-58 23.1 29.2
+main.xs Main prof-doc-last.hs:2:15-31 23.1 18.7
+last_init_xs Main prof-doc-last.hs:5:46-59 11.6 14.6
+last_xs Main prof-doc-last.hs:4:41-47 1.7 0.0
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 99 0 0.0 0.0 100.0 100.0
- CAF Main 197 0 0.0 0.0 100.0 100.0
- main Main 198 1 0.0 0.0 100.0 100.0
- last_init_ys Main 204 1 28.1 29.6 28.1 29.6
- main.ys Main 203 1 26.2 24.7 26.2 24.7
- last_ys Main 202 1 7.5 12.3 7.5 12.3
- last_init_xs Main 201 1 14.4 14.8 14.4 14.8
- main.xs Main 200 1 16.9 12.3 16.9 12.3
- last_xs Main 199 1 6.9 6.2 6.9 6.2
- CAF GHC.Conc.Signal 179 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding 163 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding.Iconv 161 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.FD 152 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.Text 150 0 0.0 0.0 0.0 0.0
+MAIN MAIN <built-in> 46 0 0.0 0.0 100.0 100.0
+ CAF Main <entire-module> 91 0 0.0 0.0 0.0 0.0
+ main Main prof-doc-last.hs:(2,1)-(7,58) 92 1 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Handle.FD <entire-module> 86 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Handle.Text <entire-module> 85 0 0.0 0.0 0.0 0.0
+ CAF GHC.Conc.Signal <entire-module> 81 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding <entire-module> 78 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding.Iconv <entire-module> 65 0 0.0 0.0 0.0 0.0
+ main Main prof-doc-last.hs:(2,1)-(7,58) 93 0 0.0 0.0 100.0 100.0
+ last_init_xs Main prof-doc-last.hs:5:46-59 96 1 11.6 14.6 11.6 14.6
+ last_init_ys Main prof-doc-last.hs:7:45-58 99 1 23.1 29.2 23.1 29.2
+ last_xs Main prof-doc-last.hs:4:41-47 94 1 1.7 0.0 1.7 0.0
+ last_ys Main prof-doc-last.hs:6:41-47 97 1 0.8 0.0 0.8 0.0
+ main.xs Main prof-doc-last.hs:2:15-31 95 1 23.1 18.7 23.1 18.7
+ main.ys Main prof-doc-last.hs:3:15-31 98 1 39.7 37.5 39.7 37.5
diff --git a/testsuite/tests/profiling/should_run/profinline001.prof.sample b/testsuite/tests/profiling/should_run/profinline001.prof.sample
index 6eacf18e1f..b1f10ed2ac 100644
--- a/testsuite/tests/profiling/should_run/profinline001.prof.sample
+++ b/testsuite/tests/profiling/should_run/profinline001.prof.sample
@@ -1,29 +1,28 @@
- Thu Apr 2 19:44 2015 Time and Allocation Profiling Report (Final)
+ Fri Jun 3 10:46 2016 Time and Allocation Profiling Report (Final)
profinline001 +RTS -p -RTS
total time = 0.00 secs (0 ticks @ 1000 us, 1 processor)
- total alloc = 49,056 bytes (excludes profiling overheads)
+ total alloc = 49,392 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-MAIN MAIN 0.0 1.4
-CAF GHC.IO.Handle.FD 0.0 70.4
-CAF GHC.IO.Encoding 0.0 5.6
-CAF GHC.Conc.Signal 0.0 1.3
-main Main 0.0 19.5
+CAF GHC.IO.Handle.FD <entire-module> 0.0 69.9
+CAF GHC.IO.Encoding <entire-module> 0.0 5.6
+CAF GHC.Conc.Signal <entire-module> 0.0 1.3
+main Main profinline001.hs:3:1-19 0.0 20.8
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 99 0 0.0 1.4 0.0 100.0
- CAF Main 197 0 0.0 0.7 0.0 20.5
- main Main 198 1 0.0 19.5 0.0 19.8
- f Main 199 1 0.0 0.3 0.0 0.4
- g Main 200 1 0.0 0.0 0.0 0.0
- CAF GHC.Conc.Signal 179 0 0.0 1.3 0.0 1.3
- CAF GHC.IO.Encoding 163 0 0.0 5.6 0.0 5.6
- CAF GHC.IO.Encoding.Iconv 161 0 0.0 0.5 0.0 0.5
- CAF GHC.IO.Handle.FD 152 0 0.0 70.4 0.0 70.4
- CAF GHC.IO.Handle.Text 150 0 0.0 0.2 0.0 0.2
+MAIN MAIN <built-in> 44 0 0.0 0.7 0.0 100.0
+ CAF Main <entire-module> 87 0 0.0 0.7 0.0 21.8
+ main Main profinline001.hs:3:1-19 88 1 0.0 20.8 0.0 21.1
+ f Main profinline001.hs:6:1-21 89 1 0.0 0.3 0.0 0.4
+ g Main profinline001.hs:8:1-11 90 1 0.0 0.0 0.0 0.0
+ CAF GHC.Conc.Signal <entire-module> 79 0 0.0 1.3 0.0 1.3
+ CAF GHC.IO.Encoding <entire-module> 76 0 0.0 5.6 0.0 5.6
+ CAF GHC.IO.Handle.FD <entire-module> 74 0 0.0 69.9 0.0 69.9
+ CAF GHC.IO.Handle.Text <entire-module> 72 0 0.0 0.2 0.0 0.2
+ CAF GHC.IO.Encoding.Iconv <entire-module> 55 0 0.0 0.5 0.0 0.5
diff --git a/testsuite/tests/profiling/should_run/scc001.prof.sample b/testsuite/tests/profiling/should_run/scc001.prof.sample
index 6df5768bc9..1144774100 100644
--- a/testsuite/tests/profiling/should_run/scc001.prof.sample
+++ b/testsuite/tests/profiling/should_run/scc001.prof.sample
@@ -1,33 +1,33 @@
- Thu Apr 2 20:30 2015 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
scc001 +RTS -hc -p -RTS
total time = 0.00 secs (0 ticks @ 1000 us, 1 processor)
- total alloc = 51,344 bytes (excludes profiling overheads)
+ total alloc = 50,888 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-MAIN MAIN 0.0 1.9
-CAF GHC.IO.Handle.FD 0.0 67.3
-CAF GHC.IO.Encoding 0.0 5.4
-CAF GHC.Conc.Signal 0.0 1.3
-main Main 0.0 22.8
+MAIN MAIN <built-in> 0.0 1.7
+CAF GHC.IO.Encoding <entire-module> 0.0 5.4
+CAF GHC.Conc.Signal <entire-module> 0.0 1.3
+CAF GHC.IO.Handle.FD <entire-module> 0.0 67.8
+main Main scc001.hs:(5,1)-(7,23) 0.0 22.5
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 98 0 0.0 1.9 0.0 100.0
- main Main 197 0 0.0 22.8 0.0 22.8
- g Main 199 1 0.0 0.0 0.0 0.0
- f Main 198 1 0.0 0.0 0.0 0.0
- CAF Main 195 0 0.0 0.1 0.0 0.1
- (...) Main 201 1 0.0 0.0 0.0 0.0
- h Main 200 1 0.0 0.0 0.0 0.0
- main Main 196 1 0.0 0.0 0.0 0.0
- CAF GHC.Conc.Signal 177 0 0.0 1.3 0.0 1.3
- CAF GHC.IO.Encoding 161 0 0.0 5.4 0.0 5.4
- CAF GHC.IO.Encoding.Iconv 159 0 0.0 0.5 0.0 0.5
- CAF GHC.IO.Handle.FD 150 0 0.0 67.3 0.0 67.3
- CAF GHC.IO.Handle.Text 148 0 0.0 0.2 0.0 0.2
- CAF GHC.Show 135 0 0.0 0.6 0.0 0.6
+MAIN MAIN <built-in> 46 0 0.0 1.7 0.0 100.0
+ CAF Main <entire-module> 91 0 0.0 0.1 0.0 0.1
+ (...) Main scc001.hs:16:1-16 97 1 0.0 0.0 0.0 0.0
+ h Main scc001.hs:16:1-16 96 1 0.0 0.0 0.0 0.0
+ main Main scc001.hs:(5,1)-(7,23) 92 1 0.0 0.0 0.0 0.0
+ CAF GHC.Show <entire-module> 88 0 0.0 0.6 0.0 0.6
+ CAF GHC.IO.Handle.FD <entire-module> 85 0 0.0 67.8 0.0 67.8
+ CAF GHC.IO.Handle.Text <entire-module> 84 0 0.0 0.2 0.0 0.2
+ CAF GHC.Conc.Signal <entire-module> 82 0 0.0 1.3 0.0 1.3
+ CAF GHC.IO.Encoding <entire-module> 79 0 0.0 5.4 0.0 5.4
+ CAF GHC.IO.Encoding.Iconv <entire-module> 65 0 0.0 0.5 0.0 0.5
+ main Main scc001.hs:(5,1)-(7,23) 93 0 0.0 22.5 0.0 22.5
+ f Main scc001.hs:10:1-7 94 1 0.0 0.0 0.0 0.0
+ g Main scc001.hs:13:1-7 95 1 0.0 0.0 0.0 0.0
diff --git a/testsuite/tests/profiling/should_run/scc002.prof.sample b/testsuite/tests/profiling/should_run/scc002.prof.sample
index 0c27b965b2..d291ba13c6 100644
--- a/testsuite/tests/profiling/should_run/scc002.prof.sample
+++ b/testsuite/tests/profiling/should_run/scc002.prof.sample
@@ -1,29 +1,30 @@
- Thu Apr 2 19:44 2015 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
- scc002 +RTS -p -RTS
+ scc002 +RTS -hc -p -RTS
- total time = 0.01 secs (7 ticks @ 1000 us, 1 processor)
- total alloc = 8,049,712 bytes (excludes profiling overheads)
+ total time = 0.01 secs (6 ticks @ 1000 us, 1 processor)
+ total alloc = 8,048,752 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-big Main 100.0 99.4
+big Main scc002.hs:24:1-57 100.0 99.4
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 113 0 0.0 0.0 100.0 100.0
- CAF Main 225 0 0.0 0.0 100.0 99.5
- yan Main 227 1 0.0 0.0 100.0 99.4
- yan.e Main 231 1 0.0 0.0 100.0 99.4
- big Main 232 1 100.0 99.4 100.0 99.4
- main Main 226 1 0.0 0.1 0.0 0.1
- yan Main 228 0 0.0 0.0 0.0 0.0
- yan.\ Main 229 2 0.0 0.0 0.0 0.0
- yan1 Main 230 2 0.0 0.0 0.0 0.0
- CAF GHC.Conc.Signal 196 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding 179 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Encoding.Iconv 177 0 0.0 0.0 0.0 0.0
- CAF GHC.IO.Handle.FD 168 0 0.0 0.4 0.0 0.4
- CAF GHC.IO.Handle.Text 166 0 0.0 0.0 0.0 0.0
+MAIN MAIN <built-in> 44 0 0.0 0.0 100.0 100.0
+ CAF Main <entire-module> 87 0 0.0 0.0 100.0 99.4
+ main Main scc002.hs:7:1-30 88 1 0.0 0.0 0.0 0.0
+ yan Main scc002.hs:26:1-52 91 0 0.0 0.0 0.0 0.0
+ yan.\ Main scc002.hs:26:31-52 92 2 0.0 0.0 0.0 0.0
+ yan1 Main scc002.hs:26:48-52 93 2 0.0 0.0 0.0 0.0
+ yan Main scc002.hs:26:1-52 90 1 0.0 0.0 100.0 99.4
+ yan.e Main scc002.hs:26:11-20 94 1 0.0 0.0 100.0 99.4
+ big Main scc002.hs:24:1-57 95 1 100.0 99.4 100.0 99.4
+ CAF GHC.IO.Handle.FD <entire-module> 81 0 0.0 0.4 0.0 0.4
+ CAF GHC.IO.Handle.Text <entire-module> 80 0 0.0 0.0 0.0 0.0
+ CAF GHC.Conc.Signal <entire-module> 77 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding <entire-module> 75 0 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Encoding.Iconv <entire-module> 61 0 0.0 0.0 0.0 0.0
+ main Main scc002.hs:7:1-30 89 0 0.0 0.1 0.0 0.1
diff --git a/testsuite/tests/profiling/should_run/scc003.prof.sample b/testsuite/tests/profiling/should_run/scc003.prof.sample
index 9e39de0866..b1c60e8199 100644
--- a/testsuite/tests/profiling/should_run/scc003.prof.sample
+++ b/testsuite/tests/profiling/should_run/scc003.prof.sample
@@ -1,35 +1,35 @@
- Tue Mar 29 16:44 2016 Time and Allocation Profiling Report (Final)
+ Sat Jun 4 11:59 2016 Time and Allocation Profiling Report (Final)
scc003 +RTS -hc -p -RTS
- total time = 0.08 secs (84 ticks @ 1000 us, 1 processor)
- total alloc = 48,880 bytes (excludes profiling overheads)
+ total time = 0.04 secs (35 ticks @ 1000 us, 1 processor)
+ total alloc = 48,704 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-fib Main 100.0 0.0
-MAIN MAIN 0.0 1.8
-CAF GHC.IO.Handle.FD 0.0 70.7
-CAF GHC.IO.Encoding 0.0 5.9
-CAF GHC.Conc.Signal 0.0 1.3
-main Main 0.0 19.5
+fib Main scc003.hs:8:1-50 100.0 0.0
+MAIN MAIN <built-in> 0.0 1.7
+CAF GHC.IO.Encoding <entire-module> 0.0 5.7
+CAF GHC.Conc.Signal <entire-module> 0.0 1.3
+CAF GHC.IO.Handle.FD <entire-module> 0.0 70.9
+main Main scc003.hs:2:1-22 0.0 19.6
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 105 0 0.0 1.8 100.0 100.0
- main Main 211 0 0.0 18.9 0.0 18.9
- CAF Main 209 0 0.0 0.0 100.0 0.7
- main Main 210 1 0.0 0.6 100.0 0.7
- f Main 212 1 0.0 0.0 100.0 0.1
- f.\ Main 216 1 0.0 0.0 100.0 0.0
- fib Main 217 2692537 100.0 0.0 100.0 0.0
- f.x' Main 215 1 0.0 0.0 0.0 0.0
- f.(...) Main 213 1 0.0 0.0 0.0 0.0
- fib Main 214 21891 0.0 0.0 0.0 0.0
- CAF GHC.Conc.Signal 203 0 0.0 1.3 0.0 1.3
- CAF GHC.IO.Encoding 193 0 0.0 5.9 0.0 5.9
- CAF GHC.IO.Encoding.Iconv 191 0 0.0 0.5 0.0 0.5
- CAF GHC.IO.Handle.FD 183 0 0.0 70.7 0.0 70.7
- CAF GHC.IO.Handle.Text 181 0 0.0 0.2 0.0 0.2
+MAIN MAIN <built-in> 44 0 0.0 1.7 100.0 100.0
+ CAF Main <entire-module> 87 0 0.0 0.0 100.0 0.7
+ main Main scc003.hs:2:1-22 88 1 0.0 0.6 100.0 0.7
+ f Main scc003.hs:5:1-41 90 1 0.0 0.0 100.0 0.1
+ f.(...) Main scc003.hs:5:11-21 91 1 0.0 0.0 0.0 0.0
+ fib Main scc003.hs:8:1-50 92 21891 0.0 0.0 0.0 0.0
+ f.\ Main scc003.hs:5:32-41 94 1 0.0 0.0 100.0 0.0
+ fib Main scc003.hs:8:1-50 95 2692537 100.0 0.0 100.0 0.0
+ f.x' Main scc003.hs:5:11-21 93 1 0.0 0.0 0.0 0.0
+ CAF GHC.IO.Handle.FD <entire-module> 82 0 0.0 70.9 0.0 70.9
+ CAF GHC.IO.Handle.Text <entire-module> 81 0 0.0 0.2 0.0 0.2
+ CAF GHC.Conc.Signal <entire-module> 79 0 0.0 1.3 0.0 1.3
+ CAF GHC.IO.Encoding <entire-module> 76 0 0.0 5.7 0.0 5.7
+ CAF GHC.IO.Encoding.Iconv <entire-module> 63 0 0.0 0.5 0.0 0.5
+ main Main scc003.hs:2:1-22 89 0 0.0 19.0 0.0 19.0
diff --git a/testsuite/tests/profiling/should_run/scc005.prof.sample b/testsuite/tests/profiling/should_run/scc005.prof.sample
index 2db2dc3e4c..2ad0f621e3 100644
--- a/testsuite/tests/profiling/should_run/scc005.prof.sample
+++ b/testsuite/tests/profiling/should_run/scc005.prof.sample
@@ -1,27 +1,26 @@
- Thu Apr 2 19:44 2015 Time and Allocation Profiling Report (Final)
+ Fri Jun 3 10:59 2016 Time and Allocation Profiling Report (Final)
scc005 +RTS -p -RTS
total time = 0.00 secs (0 ticks @ 1000 us, 1 processor)
- total alloc = 39,136 bytes (excludes profiling overheads)
+ total alloc = 39,008 bytes (excludes profiling overheads)
-COST CENTRE MODULE %time %alloc
+COST CENTRE MODULE SRC %time %alloc
-MAIN MAIN 0.0 1.2
-CAF GHC.IO.Handle.FD 0.0 88.3
-CAF GHC.IO.Encoding 0.0 7.1
-CAF GHC.Conc.Signal 0.0 1.7
+CAF GHC.IO.Handle.FD <entire-module> 0.0 88.5
+CAF GHC.IO.Encoding <entire-module> 0.0 7.1
+CAF GHC.Conc.Signal <entire-module> 0.0 1.7
- individual inherited
-COST CENTRE MODULE no. entries %time %alloc %time %alloc
+ individual inherited
+COST CENTRE MODULE SRC no. entries %time %alloc %time %alloc
-MAIN MAIN 98 0 0.0 1.2 0.0 100.0
- CAF Main 195 0 0.0 0.9 0.0 1.2
- main Main 196 1 0.0 0.2 0.0 0.3
- g Main 197 1 0.0 0.2 0.0 0.2
- f Main 198 1 0.0 0.0 0.0 0.0
- CAF GHC.Conc.Signal 177 0 0.0 1.7 0.0 1.7
- CAF GHC.IO.Encoding 161 0 0.0 7.1 0.0 7.1
- CAF GHC.IO.Encoding.Iconv 159 0 0.0 0.6 0.0 0.6
- CAF GHC.IO.Handle.FD 150 0 0.0 88.3 0.0 88.3
+MAIN MAIN <built-in> 43 0 0.0 0.9 0.0 100.0
+ CAF Main <entire-module> 85 0 0.0 0.9 0.0 1.2
+ main Main scc005.hs:10:1-22 86 1 0.0 0.2 0.0 0.3
+ g Main scc005.hs:7:1-13 87 1 0.0 0.2 0.0 0.2
+ f Main scc005.hs:3:1-9 88 1 0.0 0.0 0.0 0.0
+ CAF GHC.Conc.Signal <entire-module> 77 0 0.0 1.7 0.0 1.7
+ CAF GHC.IO.Encoding <entire-module> 74 0 0.0 7.1 0.0 7.1
+ CAF GHC.IO.Handle.FD <entire-module> 72 0 0.0 88.5 0.0 88.5
+ CAF GHC.IO.Encoding.Iconv <entire-module> 54 0 0.0 0.6 0.0 0.6