game/axl_memory.h

27 lines
771 B
C
Raw Normal View History

2025-11-23 19:12:06 +03:00
#ifndef AXL_MEMORY_H
#define AXL_MEMORY_H
#ifndef AXL_HEAP_SIZE
2025-11-24 17:52:38 +03:00
#define AXL_HEAP_SIZE 1024 * 1024 * 16
2025-11-23 19:12:06 +03:00
#endif
#include "axl_types.h"
2025-11-23 21:57:19 +03:00
void axl_init(void);
void* axl_malloc(u32 size);
2025-11-24 17:52:38 +03:00
void* axl_realloc(void* ptr, u32 size);
2025-11-23 21:57:19 +03:00
void* axl_memset(void* ptr, i8 c, u32 n);
2025-11-24 21:48:00 +03:00
void* axl_memcpy(void* dst, const void* src, u32 count);
2025-11-27 20:42:39 +03:00
i32 axl_memcmp(const void* s1, const void* s2, u32 n);
2025-12-03 16:49:54 +03:00
void* axl_memchr(const void* ptr, u8 value, u32 n);
2025-12-03 17:37:53 +03:00
void* axl_memmove(void* dst, const void* src, u32 n);
2025-11-23 21:57:19 +03:00
void axl_free(void* ptr);
2025-11-23 19:12:06 +03:00
2025-12-08 00:17:11 +03:00
#if !defined(__STDC_HOSTED__) || __STDC_HOSTED__ == 0
void* memset(void* s, int c, size_t n);
void* memcpy(void* dst, const void* src, unsigned long long count);
void* memmove(void* dst, const void* src, size_t n);
#endif
2025-11-23 19:12:06 +03:00
#endif