n_chunks
chunks each with
sizeof (TYPE) size.
#include <ace/Malloc_T.h>
template<class T, class ACE_LOCK> class ACE_Cached_Allocator : public ACE_New_Allocator {
public:
ACE_Cached_Allocator (size_t n_chunks);
~ACE_Cached_Allocator (void);
void* malloc (size_t);
void free (void *);
private:
char *pool_;
ACE_Locked_Free_List<ACE_Cached_Mem_Pool_Node<T>, ACE_LOCK> free_list_;};
ACE_Cached_Allocator (size_t n_chunks);
n_chunks
chunks
each with sizeof (TYPE) size.
~ACE_Cached_Allocator (void);
void* malloc (size_t);
void free (void *);
char *pool_;
ACE_Locked_Free_List<ACE_Cached_Mem_Pool_Node<T>, ACE_LOCK> free_list_;