LF MPMC queue improvements
Small improvements of the LF MPMC queue Making the LF MPMC queue generic and in a seperate header file
This commit is contained in:
47
arena.h
47
arena.h
@@ -1,45 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "base.h"
|
||||
|
||||
// #define _CRT_SECURE_NO_WARNINGS
|
||||
//
|
||||
// #include <assert.h>
|
||||
// #include <stdbool.h>
|
||||
// #include <stdint.h>
|
||||
// #include <stdio.h>
|
||||
// #include <string.h>
|
||||
//
|
||||
// /* ------------------------------------------------------------
|
||||
// Base types
|
||||
// ------------------------------------------------------------ */
|
||||
//
|
||||
// typedef uint8_t u8;
|
||||
// typedef uint32_t u32;
|
||||
// typedef uint64_t u64;
|
||||
// typedef int32_t i32;
|
||||
// typedef int b32;
|
||||
//
|
||||
// /* ------------------------------------------------------------
|
||||
// Size helpers
|
||||
// ------------------------------------------------------------ */
|
||||
//
|
||||
// #define KiB(x) ((u64)(x) * 1024ULL)
|
||||
// #define MiB(x) (KiB(x) * 1024ULL)
|
||||
//
|
||||
// /* ------------------------------------------------------------
|
||||
// Alignment helpers
|
||||
// ------------------------------------------------------------ */
|
||||
//
|
||||
// #define ALIGN_UP_POW2(x, a) (((x) + ((a) - 1)) & ~((a) - 1))
|
||||
//
|
||||
// /* ------------------------------------------------------------
|
||||
// Assert
|
||||
// ------------------------------------------------------------ */
|
||||
//
|
||||
// #ifndef ASSERT
|
||||
// #define ASSERT(x) assert(x)
|
||||
// #endif
|
||||
//
|
||||
/*
|
||||
===============================================================================
|
||||
ARENA USAGE GUIDE
|
||||
@@ -417,10 +379,3 @@ void arena_scratch_release(mem_arena_temp scratch);
|
||||
#define ARENA_PUSH_NZ(arena, size) arena_push((arena), (size), false)
|
||||
|
||||
#define arena_pop(arena_ptr) arena_pop_to((arena_ptr), 1)
|
||||
|
||||
u32 plat_get_pagesize(void);
|
||||
|
||||
void *plat_mem_reserve(u64 size);
|
||||
b32 plat_mem_commit(void *ptr, u64 size);
|
||||
b32 plat_mem_decommit(void *ptr, u64 size);
|
||||
b32 plat_mem_release(void *ptr, u64 size);
|
||||
|
||||
Reference in New Issue
Block a user