diff options
author | marcus <marcus> | 2003-08-16 21:21:45 +0000 |
---|---|---|
committer | marcus <marcus> | 2003-08-16 21:21:45 +0000 |
commit | b4db08293ac7ac5480e7cf416dab10b5dea6132e (patch) | |
tree | e40cd13f5b68bcc2e70edcc74259a722f8865788 /libhurd-slab | |
parent | 355ca868e6fb1072f617d86f84736c7982492866 (diff) |
Add README file.
Diffstat (limited to 'libhurd-slab')
-rw-r--r-- | libhurd-slab/README | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/libhurd-slab/README b/libhurd-slab/README new file mode 100644 index 0000000..a3309b6 --- /dev/null +++ b/libhurd-slab/README @@ -0,0 +1,23 @@ +Slab Allocator +============== + +If a program requires many objects of the same type, which are created +and destroyed often, then it can be better to not use a general +purpose allocation strategy like malloc(), but a special arena (or +other backing memory) and a special purpose allocator that can take +advantage of the fact that all objects are of the same size. + +In addition, such objects usually have an initial stage that is +naturally returned to when the object is not needed anymore. For +example locks are unlocked, reference counters are zero, etc. In such +a situation, performance can be further increased by caching the +unused objects, instead of destroying them. + +The following article gives more information about such caching object +allocators: + +http://citeseer.nj.nec.com/bonwick94slab.html + +The current implementation in libhurd-slab is only a dummy +implementation using malloc and free, though. + |