diff options
Diffstat (limited to 'src/memory.cc')
| -rw-r--r-- | src/memory.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/memory.cc b/src/memory.cc index c27c6f3..518b761 100644 --- a/src/memory.cc +++ b/src/memory.cc @@ -2,8 +2,8 @@ #define MEMORY_CC #include "common.cc" -#include <cstdlib> #include <cstring> +#include <mimalloc.h> typedef u8* (*Allocator_Allocate)(u8* self, usize length, usize align); typedef void (*Allocator_Deallocate)(u8* self, u8* ptr); @@ -24,12 +24,12 @@ void deallocate(Allocator* allocator, u8* ptr) { static inline u8* heap_allocate(u8* self, usize size, usize align) { (void)self; - return (u8*)aligned_alloc(align, size); + return (u8*)mi_aligned_alloc(align, size); } static inline void heap_deallocate(u8* self, u8* ptr) { (void)self; - free(ptr); + mi_free(ptr); } Allocator* heap_allocator() { |
