pike.git/
src/
gc.c
Branch:
Tag:
Non-build tags
All tags
No tags
2012-07-03
2012-07-03 15:10:24 by Arne Goedeke <el@laramies.com>
df02cff9f9c3b86ecfa83b8c60d44daebf7f3e95 (
5
lines) (+
3
/-
2
)
[
Show
|
Annotate
]
Branch:
arne/block_alloc
use same amount of pages, as the old allocator
436:
#include "gjalloc.h" struct block_allocator gc_rec_frame_allocator =
-
BA_INIT(sizeof(struct gc_rec_frame),
4096/sizeof(struct gc
_
rec
_
frame
)
)
;
+
BA_INIT
_PAGES
(sizeof(struct gc_rec_frame),
2*PIKE
_
MALLOC
_
PAGE_SIZE
);
static INLINE void really_free_gc_rec_frame(struct gc_rec_frame * f) { #ifdef PIKE_DEBUG
479:
BLOCK_ALLOC_FILL_PAGES (ba_mixed_frame, 2) #else static struct block_allocator ba_mixed_frame_allocator
-
= BA_INIT(sizeof(struct ba_mixed_frame),
4096/sizeof(struct ba
_
mixed
_
frame
)
)
;
+
= BA_INIT
_PAGES
(sizeof(struct ba_mixed_frame),
2*PIKE
_
MALLOC
_
PAGE_SIZE
);
void count_memory_in_ba_mixed_frames(size_t *num, size_t * size) { ba_count_all(&ba_mixed_frame_allocator, num, size);