Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
30387408
Commit
30387408
authored
Apr 16, 2008
by
simonmarhaskell@gmail.com
Browse files
add debugging code to check for fragmentation
parent
0b43af1b
Changes
1
Hide whitespace changes
Inline
Side-by-side
rts/sm/BlockAlloc.c
View file @
30387408
...
...
@@ -331,6 +331,14 @@ allocGroup (nat n)
}
if
(
ln
==
MAX_FREE_LIST
)
{
#if 0
if ((mblocks_allocated * MBLOCK_SIZE_W - n_alloc_blocks * BLOCK_SIZE_W) > (1024*1024)/sizeof(W_)) {
debugBelch("Fragmentation, wanted %d blocks:", n);
RtsFlags.DebugFlags.block_alloc = 1;
checkFreeListSanity();
}
#endif
bd
=
alloc_mega_group
(
1
);
bd
->
blocks
=
n
;
initGroup
(
n
,
bd
);
// we know the group will fit
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment