2 #ifndef __OSI_MCAS_OBJ_CACHE_H
3 #define __OSI_MCAS_OBJ_CACHE_H
5 #include "../mcas/portable_defns.h"
6 #include "../mcas/ptst.h"
7 #include "../mcas/gc.h"
9 typedef int osi_mcas_obj_cache_t
;
11 /* Create a new MCAS GC pool, and return its identifier, which
12 * follows future calls */
13 void osi_mcas_obj_cache_create(osi_mcas_obj_cache_t
* gc_id
, size_t size
,
14 char *tag
); /* alignment? */
16 /* Allocate an object from the pool identified by
18 void *osi_mcas_obj_cache_alloc(osi_mcas_obj_cache_t gc_id
);
20 /* Release object obj to its GC pool, identified by
22 void osi_mcas_obj_cache_free(osi_mcas_obj_cache_t gc_id
, void *obj
);
24 /* Terminate an MCAS GC pool */
25 void osi_mcas_obj_cache_destroy(osi_mcas_obj_cache_t gc_id
);
27 #endif /* __OSI_MCAS_OBJ_CACHE_H */