diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2024-11-02 10:03:22 -0400 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2024-11-04 12:26:14 -0500 |
commit | 624d63410a919f8cf9f8f757b02ca8b91111e969 (patch) | |
tree | 67d2f181a1dc45e481465b418334440e329999e9 /src/alloc.h | |
parent | 8eb18cdb65e3fd6111fc50ac5a69d3f7094dd54c (diff) | |
download | bfs-624d63410a919f8cf9f8f757b02ca8b91111e969.tar.xz |
alloc: Switch arenas from a freelist to a bitmap allocator
Diffstat (limited to 'src/alloc.h')
-rw-r--r-- | src/alloc.h | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/alloc.h b/src/alloc.h index c4badc4..af8b391 100644 --- a/src/alloc.h +++ b/src/alloc.h @@ -241,12 +241,10 @@ void *reserve(void *ptr, size_t align, size_t size, size_t count); * Arena allocators are intentionally not thread safe. */ struct arena { - /** The list of free chunks. */ - void *chunks; /** The number of allocated slabs. */ size_t nslabs; /** The array of slabs. */ - void **slabs; + struct slab **slabs; /** Chunk alignment. */ size_t align; /** Chunk size. */ |