add KB, MB and GB macros

This commit is contained in:
2025-10-04 20:55:15 +02:00
parent 23cec15758
commit e585134339
+3
View File
@@ -6,6 +6,9 @@
#include <stdlib.h> #include <stdlib.h>
#define MAX_ALIGN (sizeof(union { char c; int i; long l; long long ll; float f; double d; void *p; })) #define MAX_ALIGN (sizeof(union { char c; int i; long l; long long ll; float f; double d; void *p; }))
#define KB (1024)
#define MB (KB * KB)
#define GB (KB * KB * KB)
// Contains all operations an allocator can do. Similar interface to sdtlibs // Contains all operations an allocator can do. Similar interface to sdtlibs
// malloc, realloc and free. // malloc, realloc and free.