From bc53100f1ef063e09d77e8670e1796bc67017411 Mon Sep 17 00:00:00 2001 From: Nicholas Noll Date: Tue, 28 Sep 2021 13:39:24 -0700 Subject: Checkin: various small changes --- include/libn.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'include/libn.h') diff --git a/include/libn.h b/include/libn.h index 2cf29c7..699786f 100644 --- a/include/libn.h +++ b/include/libn.h @@ -57,6 +57,7 @@ typedef struct mem·Allocator { void *(*alloc)(void *heap, uint n, ulong size); void (*free)(void *heap, void *ptr); } mem·Allocator; + extern mem·Allocator sys·Memory; typedef struct mem·Reallocator { @@ -64,6 +65,7 @@ typedef struct mem·Reallocator { void *(*realloc)(void *iface, void *ptr, uint n, ulong size); void (*free)(void *iface, void *ptr); } mem·Reallocator; + extern mem·Reallocator sys·Relocator; /* simple memory arena */ @@ -73,6 +75,8 @@ mem·Arena *mem·makearena(mem·Allocator from, void*); void *mem·arenaalloc(mem·Arena *A, uint n, ulong size); void mem·freearena(mem·Arena *A); +extern mem·Allocator mem·ArenaAllocator; + /* generalized memxxx functions */ void memset64(void *dst, uint64 val, uintptr size); -- cgit v1.2.1