aboutsummaryrefslogtreecommitdiff
path: root/include/libn.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/libn.h')
-rw-r--r--include/libn.h4
1 files changed, 4 insertions, 0 deletions
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);