Commit 6f4b7427 authored by Simon Marlow's avatar Simon Marlow

FILL_SLOP: don't fill slop for BLACKHOLE/CAF_BLACKHOLE

This affects -debug only, avoids crash with test conc012.
parent 8edc7cea
......@@ -233,6 +233,10 @@ FILL_SLOP(StgClosure *p)
switch (inf->type) {
case BLACKHOLE:
case CAF_BLACKHOLE:
goto no_slop;
// we already filled in the slop when we overwrote the thunk
// with BLACKHOLE, and also an evacuated BLACKHOLE is only the
// size of an IND.
case THUNK_SELECTOR:
sz = sizeofW(StgSelector) - sizeofW(StgThunkHeader);
break;
......@@ -249,6 +253,8 @@ FILL_SLOP(StgClosure *p)
for (i = 0; i < sz; i++) {
((StgThunk *)p)->payload[i] = 0;
}
no_slop:
;
}
#endif /* CMINUSMINUS */
......
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