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:
4adc53f
)
Retract Hp *before* checking for HpLim==0
author
Simon Marlow
<marlowsd@gmail.com>
Mon, 16 Mar 2009 16:05:00 +0000
(16:05 +0000)
committer
Simon Marlow
<marlowsd@gmail.com>
Mon, 16 Mar 2009 16:05:00 +0000
(16:05 +0000)
Fixes heapprof001(prof_hp) following the recent HpLim patch, which
depended on the lack of slop in the heap.
rts/HeapStackCheck.cmm
patch
|
blob
|
history
diff --git
a/rts/HeapStackCheck.cmm
b/rts/HeapStackCheck.cmm
index
10baca2
..
1533ae0
100644
(file)
--- a/
rts/HeapStackCheck.cmm
+++ b/
rts/HeapStackCheck.cmm
@@
-63,11
+63,11
@@
import LeaveCriticalSection;
#define GC_GENERIC \
DEBUG_ONLY(foreign "C" heapCheckFail()); \
if (Hp > HpLim) { \
+ Hp = Hp - HpAlloc/*in bytes*/; \
if (HpLim == 0) { \
R1 = ThreadYielding; \
goto sched; \
} \
- Hp = Hp - HpAlloc/*in bytes*/; \
if (HpAlloc <= BLOCK_SIZE \
&& bdescr_link(CurrentNursery) != NULL) { \
CLOSE_NURSERY(); \