projects
/
ghc-hetmet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a7f3dd0
)
FIX crash on exit with biographical profiling
author
Simon Marlow
<simonmar@microsoft.com>
Tue, 8 May 2007 10:09:08 +0000
(10:09 +0000)
committer
Simon Marlow
<simonmar@microsoft.com>
Tue, 8 May 2007 10:09:08 +0000
(10:09 +0000)
Seems to be a bug introduced by code to free the memory allocated by
the heap profiler.
rts/ProfHeap.c
patch
|
blob
|
history
diff --git
a/rts/ProfHeap.c
b/rts/ProfHeap.c
index
76a6b33
..
19abac7
100644
(file)
--- a/
rts/ProfHeap.c
+++ b/
rts/ProfHeap.c
@@
-523,11
+523,13
@@
endHeapProfiling(void)
}
#endif
}
#endif
- {
+ if (doingLDVProfiling()) {
nat t;
nat t;
- for (t = 0; t <= era; t++) {
+ for (t = 1; t <= era; t++) {
freeEra( &censuses[t] );
}
freeEra( &censuses[t] );
}
+ } else {
+ freeEra( &censuses[0] );
}
stgFree(censuses);
}
stgFree(censuses);