blob: ac03e6f1a3716650a7f0aa115b7e3a98af4af219 (
plain) (
tree)
|
|
# arena
Minimal arena allocator for C.
## Installation
The **arena.c** and **arena.h** files can be dropped into an existing C project
and compiled it along it.
## Usage
- `arena_t* arena_create_sized(size_t size);`: Create an arena with size `size`
- `arena_t* arena_create(void);`: Create an arena with a compile-time specified
page size (4096 by default)
- `void* arena_malloc(arena_t* arena, size_t size);`: Allocate `size` bytes inside
the arena
- `void arena_destroy(arena_t* arena);`: Destroy the arena
|