1
0
mirror of https://github.com/adtools/clib2.git synced 2025-12-08 14:59:05 +00:00

Added a slab allocator

Added a slab allocator which replaces the use of memory pools or the plain AllocMem() operations, respectively. In order to activate the slab allocator, choose a slab size (e.g. 2048 bytes or 4096 bytes) and declare a global variable like this:

   ULONG __slab_max_size = 2048;

Memory allocations smaller than the slab size will be made from "slabs", i.e. large chunks of memory of the given size. Larger allocations will be managed separately.
This commit is contained in:
obarthel
2016-11-18 17:22:21 +01:00
parent eb223f269d
commit fbc8694c49
22 changed files with 786 additions and 495 deletions

View File

@ -1 +1 @@
206
207