Mercurial > hg > xemacs-beta
comparison src/mc-alloc.c @ 2994:ec5f23ea6d2e
[xemacs-hg @ 2005-10-14 01:21:57 by ben]
add gc percentage threshold to mc-alloc
config.h.in, alloc.c, dumper.c, emacs.c, lrecord.h, mc-alloc.c, mc-alloc.h, symbols.c: Rename MC_ALLOC_TYPE_STATS to ALLOC_TYPE_STATS, since
(with refactoring) this is not really specific to mc-alloc.
Generalize code to implement the GC % threshold for garbage
collecting. Rename `lrecord-stats' to `object-memory-usage-stats'
(defined when not mc-alloc, too). Rename `memory-usage' to
`total-memory-usage' and add `object-memory-usage'. Bump
gc_cons_threshold to 2,000,000 (suggestion by Stephen Turnbull).
Avoid use of C++ reserved word `catch'.
Change address for crash reporting to xemacs-beta@xemacs.org from
crashes@xemacs.org.
new -> new_ in emacs.c.
Turn on _CRT_SECURE_NO_DEPRECATE under Visual C++ to avoid tons of
warnings in VC8.
author | ben |
---|---|
date | Fri, 14 Oct 2005 01:22:01 +0000 |
parents | 6c70efc2b5b1 |
children | 141c2920ea48 |
comparison
equal
deleted
inserted
replaced
2993:49316578f12d | 2994:ec5f23ea6d2e |
---|---|
1484 else | 1484 else |
1485 PLH_USED_SPACE (PH_PLH (ph)) -= PH_CELL_SIZE (ph); | 1485 PLH_USED_SPACE (PH_PLH (ph)) -= PH_CELL_SIZE (ph); |
1486 #endif | 1486 #endif |
1487 if (PH_ON_USED_LIST_P (ph)) | 1487 if (PH_ON_USED_LIST_P (ph)) |
1488 { | 1488 { |
1489 #ifdef MC_ALLOC_TYPE_STATS | 1489 #ifdef ALLOC_TYPE_STATS |
1490 dec_lrecord_stats (PH_CELL_SIZE (ph), | 1490 dec_lrecord_stats (PH_CELL_SIZE (ph), |
1491 (const struct lrecord_header *) ptr); | 1491 (const struct lrecord_header *) ptr); |
1492 #endif /* MC_ALLOC_TYPE_STATS */ | 1492 #endif /* ALLOC_TYPE_STATS */ |
1493 #ifdef ERROR_CHECK_GC | 1493 #ifdef ERROR_CHECK_GC |
1494 assert (!LRECORD_FREE_P (ptr)); | 1494 assert (!LRECORD_FREE_P (ptr)); |
1495 deadbeef_memory (ptr, PH_CELL_SIZE (ph)); | 1495 deadbeef_memory (ptr, PH_CELL_SIZE (ph)); |
1496 MARK_LRECORD_AS_FREE (ptr); | 1496 MARK_LRECORD_AS_FREE (ptr); |
1497 #endif | 1497 #endif |