lurscher
lurscher

Reputation: 26943

memory manager that manages a pre allocated block

I'm trying to find a memory management library for C++ that would allocate from an pre-allocated memory block i give it in order to initialise it. After i'm done i will close the allocator (and objects) and free the preallocated block

does something like this already exists?

Upvotes: 2

Views: 1269

Answers (2)

justin
justin

Reputation: 104698

you may be interested in loki's allocators:

http://sourceforge.net/projects/loki-lib/

Upvotes: 1

Crashworks
Crashworks

Reputation: 41374

There are many such allocators. dlmalloc is one of the most popular (and it's worked well for us). Doug Lea has malloc.c and malloc.h available for download, and there are also several derivatives of his original code that are packaged up in possibly more convenient ways, such as ptmalloc.

Upvotes: 1

Related Questions