summaryrefslogtreecommitdiff
path: root/source/base/base_arena.h
diff options
context:
space:
mode:
authornasr <nsrddyn@gmail.com>2026-04-17 17:49:10 +0200
committernasr <nsrddyn@gmail.com>2026-04-17 17:50:28 +0200
commit078e21a1feb811f9ef7797ce3ee5d2e8ffcccfce (patch)
treec1121bed141fb536be6b21a6fc54ccd2b5ac7302 /source/base/base_arena.h
parent9d09d66a273f68fae7efb71504bf40c664b91983 (diff)
feature(main): during my work on other projects I improved the base library a bit.
this is a drag and drop of that in the project. the next steps exit out of implementing lineair regression and attempting to calcualte what the value would be of a key in the btree... Signed-off-by: nasr <nsrddyn@gmail.com> feature(main): during my work on other projects I improved the base library a bit. this is a drag and drop of that in the project. the next steps exit out of implementing lineair regression and attempting to calcualte what the value would be of a key in the btree... Signed-off-by: nasr <nsrddyn@gmail.com>
Diffstat (limited to 'source/base/base_arena.h')
-rwxr-xr-xsource/base/base_arena.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/base/base_arena.h b/source/base/base_arena.h
index 2818ae4..dc6dd73 100755
--- a/source/base/base_arena.h
+++ b/source/base/base_arena.h
@@ -7,6 +7,11 @@
7#define PushArray(arena, type, len) (type *)arena_alloc((arena), sizeof(type) * (len), 0) 7#define PushArray(arena, type, len) (type *)arena_alloc((arena), sizeof(type) * (len), 0)
8#define PushArrayZero(arena, type, len) (type *)arena_alloc((arena), sizeof(type) * (len), 1) 8#define PushArrayZero(arena, type, len) (type *)arena_alloc((arena), sizeof(type) * (len), 1)
9 9
10#define KiB(n) (((u64)(n)) << 10)
11#define MiB(n) (((u64)(n)) << 20)
12#define GiB(n) (((u64)(n)) << 30)
13
14
10typedef struct mem_arena mem_arena; 15typedef struct mem_arena mem_arena;
11struct mem_arena 16struct mem_arena
12{ 17{