4coder/custom/4coder_app_links_allocator.cpp

43 lines
1.0 KiB
C++
Raw Normal View History

2019-06-01 23:58:28 +00:00
/*
* 4coder app links base allocator
*/
// TOP
Scratch_Block::Scratch_Block(Application_Links *app, Scratch_Share_Code share){
scratch_block__init(this, get_thread_context(app), share);
2019-06-01 23:58:28 +00:00
}
Scratch_Block::Scratch_Block(Application_Links *app){
scratch_block__init(this, get_thread_context(app), share_code_default);
2019-06-01 23:58:28 +00:00
}
////////////////////////////////
2019-06-01 23:58:28 +00:00
internal Arena*
reserve_arena(Application_Links *app, umem chunk_size, umem align){
Thread_Context *tctx = get_thread_context(app);
return(reserve_arena(tctx, chunk_size, align));
2019-06-01 23:58:28 +00:00
}
internal Arena*
reserve_arena(Application_Links *app, umem chunk_size){
Thread_Context *tctx = get_thread_context(app);
return(reserve_arena(tctx, chunk_size));
2019-06-01 23:58:28 +00:00
}
internal Arena*
reserve_arena(Application_Links *app){
Thread_Context *tctx = get_thread_context(app);
return(reserve_arena(tctx));
2019-06-01 23:58:28 +00:00
}
internal void
release_arena(Application_Links *app, Arena *arena){
Thread_Context *tctx = get_thread_context(app);
release_arena(tctx, arena);
2019-06-01 23:58:28 +00:00
}
// BOTTOM