2010-01-17 01:53:50 +08:00
|
|
|
/******************************************************************************/
|
|
|
|
#ifdef JEMALLOC_H_TYPES
|
|
|
|
|
|
|
|
typedef struct extent_node_s extent_node_t;
|
|
|
|
|
|
|
|
#endif /* JEMALLOC_H_TYPES */
|
|
|
|
/******************************************************************************/
|
|
|
|
#ifdef JEMALLOC_H_STRUCTS
|
|
|
|
|
|
|
|
/* Tree of extents. */
|
|
|
|
struct extent_node_s {
|
|
|
|
/* Linkage for the size/address-ordered tree. */
|
2010-02-11 02:37:56 +08:00
|
|
|
rb_node(extent_node_t) link_szad;
|
2010-01-17 01:53:50 +08:00
|
|
|
|
|
|
|
/* Linkage for the address-ordered tree. */
|
2010-02-11 02:37:56 +08:00
|
|
|
rb_node(extent_node_t) link_ad;
|
|
|
|
|
|
|
|
/* Profile counters, used for huge objects. */
|
2010-04-14 07:13:54 +08:00
|
|
|
prof_ctx_t *prof_ctx;
|
2010-01-17 01:53:50 +08:00
|
|
|
|
|
|
|
/* Pointer to the extent that this tree node is responsible for. */
|
2010-02-11 02:37:56 +08:00
|
|
|
void *addr;
|
2010-01-17 01:53:50 +08:00
|
|
|
|
|
|
|
/* Total region size. */
|
2010-02-11 02:37:56 +08:00
|
|
|
size_t size;
|
2012-10-09 08:56:11 +08:00
|
|
|
|
|
|
|
/* True if zero-filled; used by chunk recycling code. */
|
|
|
|
bool zeroed;
|
2010-01-17 01:53:50 +08:00
|
|
|
};
|
|
|
|
typedef rb_tree(extent_node_t) extent_tree_t;
|
|
|
|
|
|
|
|
#endif /* JEMALLOC_H_STRUCTS */
|
|
|
|
/******************************************************************************/
|
|
|
|
#ifdef JEMALLOC_H_EXTERNS
|
|
|
|
|
|
|
|
rb_proto(, extent_tree_szad_, extent_tree_t, extent_node_t)
|
|
|
|
|
|
|
|
rb_proto(, extent_tree_ad_, extent_tree_t, extent_node_t)
|
|
|
|
|
|
|
|
#endif /* JEMALLOC_H_EXTERNS */
|
|
|
|
/******************************************************************************/
|
|
|
|
#ifdef JEMALLOC_H_INLINES
|
|
|
|
|
|
|
|
#endif /* JEMALLOC_H_INLINES */
|
|
|
|
/******************************************************************************/
|
|
|
|
|