# Memory Pool --- ## Object Definitions ```c #define POOL_HEADER(STRUCT) struct STRUCT *prev, *next; uint32_t obj_size typedef struct _kpl_pool_obj { POOL_HEADER(_kpl_pool_obj); } kpl_pool_obj; typedef strut { _Atomic size_t allocs; kpl_pool_obj *root; pthread_mutex_t mutex; } kpl_pool; static kpl_pool_obj *kpl_pool_head; ``` ## Object Size The max size of an object in the pool is 2 \*\* 32 This allows for 4 aligned bytes after the `POOL_HEADER` macro ## List Management ## Tree Management