1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-11 05:51:21 -08:00
emacs/mps/code/poolmv.h
Richard Brooksby 3d5e2ca85f Adding hopenames back into the master sources, so that they can be included in the union sources along with the id keywords.
This was achieved by partially undoing changelist 24817, including an accidental corruption of eventgen.pl.

Copied from Perforce
 Change: 24877
 ServerID: perforce.ravenbrook.com
2001-12-06 18:14:02 +00:00

57 lines
1.7 KiB
C

/* .impl.h.poolmv: MANUAL VARIABLE POOL
*
* $Id$
* $HopeName: MMsrc!poolmv.h(trunk.7) $
* Copyright (c) 2001 Ravenbrook Limited.
*
* .purpose: This is the interface to the manual-variable pool class.
*
* .mv: Manual-variable pools manage variably-sized blocks of memory in a
* flexible manner. They have higher overheads than a fixed-size pool.
*
* .init: This class adds the following arguments to PoolCreate:
*
* Size extendBy
*
* extendBy is the default number of bytes reserved by the pool at a time.
* A large size will make allocation cheaper but have a higher resource
* overhead. A typical value might be 65536. See note 2.
*
* Size avgSize
*
* avgSize is an estimate of the average size of an allocation, and is used
* to choose the size of internal tables. An accurate estimate will
* improve the efficiency of the pool. A low estimate will make the pool
* less space efficient. A high estimate will make the pool less time
* efficient. A typical value might be 32. avgSize must not be less than
* extendBy.
*
* Size maxSize
*
* maxSize is an estimate of the maximum total size that the pool will
* reach. Setting this parameter does not actually contrain the pool, but
* an accurate estimate will improve the efficiency of the pool. maxSize
* must not be less than extendBy.
*
* Notes
* 2. The documentation could suggest a segment size according to the
* distribution of allocation size requests. richard 1994-11-08
*/
#ifndef poolmv_h
#define poolmv_h
#include "mpmtypes.h"
typedef struct MVStruct *MV;
extern PoolClass PoolClassMV(void);
extern Bool MVCheck(MV mv);
#define MVPool(mv) (&(mv)->poolStruct)
extern Pool (MVPool)(MV mv);
#endif /* poolmv_h */