mirror of
https://gitlab.labs.nic.cz/labs/bird.git
synced 2024-05-11 16:54:54 +00:00
Memory pages allocator is now a global simple lockless structure
This commit is contained in:
@@ -122,6 +122,7 @@ void buffer_realloc(void **buf, unsigned *size, unsigned need, unsigned item_siz
|
||||
/* Allocator of whole pages; for use in slabs and other high-level allocators. */
|
||||
#define PAGE_HEAD(x) ((void *) (((uintptr_t) (x)) & ~(page_size-1)))
|
||||
extern long page_size;
|
||||
extern _Atomic int pages_kept;
|
||||
void *alloc_page(void);
|
||||
void free_page(void *);
|
||||
|
||||
|
Reference in New Issue
Block a user