2010-01-24 18:53:40 +08:00
|
|
|
#ifdef JEMALLOC_SWAP
|
|
|
|
/******************************************************************************/
|
|
|
|
#ifdef JEMALLOC_H_TYPES
|
|
|
|
|
|
|
|
#endif /* JEMALLOC_H_TYPES */
|
|
|
|
/******************************************************************************/
|
|
|
|
#ifdef JEMALLOC_H_STRUCTS
|
|
|
|
|
|
|
|
#endif /* JEMALLOC_H_STRUCTS */
|
|
|
|
/******************************************************************************/
|
|
|
|
#ifdef JEMALLOC_H_EXTERNS
|
|
|
|
|
|
|
|
extern malloc_mutex_t swap_mtx;
|
|
|
|
extern bool swap_enabled;
|
2010-01-28 05:10:55 +08:00
|
|
|
extern bool swap_prezeroed;
|
|
|
|
extern size_t swap_nfds;
|
|
|
|
extern int *swap_fds;
|
2010-01-24 18:53:40 +08:00
|
|
|
#ifdef JEMALLOC_STATS
|
|
|
|
extern size_t swap_avail;
|
|
|
|
#endif
|
|
|
|
|
2010-01-25 09:13:07 +08:00
|
|
|
void *chunk_alloc_swap(size_t size, bool *zero);
|
2010-12-01 08:50:58 +08:00
|
|
|
bool chunk_in_swap(void *chunk);
|
2010-01-24 18:53:40 +08:00
|
|
|
bool chunk_dealloc_swap(void *chunk, size_t size);
|
|
|
|
bool chunk_swap_enable(const int *fds, unsigned nfds, bool prezeroed);
|
|
|
|
bool chunk_swap_boot(void);
|
|
|
|
|
|
|
|
#endif /* JEMALLOC_H_EXTERNS */
|
|
|
|
/******************************************************************************/
|
|
|
|
#ifdef JEMALLOC_H_INLINES
|
|
|
|
|
|
|
|
#endif /* JEMALLOC_H_INLINES */
|
|
|
|
/******************************************************************************/
|
|
|
|
#endif /* JEMALLOC_SWAP */
|