1 #ifndef _XBT_MALLOCATOR_H
2 #define _XBT_MALLOCATOR_H
4 #include "xbt/function_types.h"
5 #include "xbt/misc.h" /* SG_BEGIN_DECL */
9 /* mallocator data type (opaque structure) */
10 typedef struct s_xbt_mallocator *xbt_mallocator_t;
12 /* creation and destruction */
13 xbt_mallocator_t xbt_mallocator_new(int size, pvoid_f_void_t new_f, void_f_pvoid_t free_f, void_f_pvoid_t reset_f);
14 void xbt_mallocator_free(xbt_mallocator_t mallocator);
17 void *xbt_mallocator_get(xbt_mallocator_t mallocator);
18 void xbt_mallocator_release(xbt_mallocator_t mallocator, void *object);
22 #endif /* _XBT_MALLOCATOR_H */