preliminary work on sea of nodes based intermediate representation.
This commit is contained in:
parent
989a32fa7b
commit
849e0b6863
13 changed files with 918 additions and 58 deletions
4
utils.c
4
utils.c
|
|
@ -112,10 +112,12 @@ static usize align_forward(usize ptr, usize align) {
|
|||
|
||||
arena arena_init(usize size)
|
||||
{
|
||||
void *memory = malloc(size);
|
||||
memset(memory, 0x0, size);
|
||||
return (arena){
|
||||
.capacity = size,
|
||||
.position = 0,
|
||||
.memory = malloc(size),
|
||||
.memory = memory,
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue