mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-08-01 11:48:10 +00:00
eliminate standalone programs for pdb -> rdi; dwarf -> rdi; pdb -> breakpad; sketch out 'radbin', unified cli frontend for dumping/converting/etc., plug in pdb -> rdi, pdb -> breakpad, & stub out dumper/dwarf
This commit is contained in:
@@ -234,6 +234,39 @@ async_execute_work(ASYNC_Work work)
|
||||
}
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Root Allocation/Deallocation
|
||||
|
||||
internal ASYNC_Root *
|
||||
async_root_alloc(void)
|
||||
{
|
||||
Arena *arena = arena_alloc();
|
||||
ASYNC_Root *root = push_array(arena, ASYNC_Root, 1);
|
||||
root->arenas = push_array(arena, Arena *, async_thread_count());
|
||||
root->arenas[0] = arena;
|
||||
for(U64 idx = 1; idx < async_thread_count(); idx += 1)
|
||||
{
|
||||
root->arenas[idx] = arena_alloc();
|
||||
}
|
||||
return root;
|
||||
}
|
||||
|
||||
internal void
|
||||
async_root_release(ASYNC_Root *root)
|
||||
{
|
||||
for(U64 idx = 1; idx < async_thread_count(); idx += 1)
|
||||
{
|
||||
arena_release(root->arenas[idx]);
|
||||
}
|
||||
arena_release(root->arenas[0]);
|
||||
}
|
||||
|
||||
internal Arena *
|
||||
async_root_thread_arena(ASYNC_Root *root)
|
||||
{
|
||||
return root->arenas[async_work_thread_idx];
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Work Thread Entry Point
|
||||
|
||||
|
||||
@@ -70,6 +70,15 @@ struct ASYNC_TaskList
|
||||
U64 count;
|
||||
};
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Root (Per-Worker-Thread Arena Bundle)
|
||||
|
||||
typedef struct ASYNC_Root ASYNC_Root;
|
||||
struct ASYNC_Root
|
||||
{
|
||||
Arena **arenas;
|
||||
};
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Shared State Bundle
|
||||
|
||||
@@ -138,6 +147,13 @@ internal void *async_task_join(ASYNC_Task *task);
|
||||
internal ASYNC_Work async_pop_work(void);
|
||||
internal void async_execute_work(ASYNC_Work work);
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Root Allocation/Deallocation
|
||||
|
||||
internal ASYNC_Root *async_root_alloc(void);
|
||||
internal void async_root_release(ASYNC_Root *root);
|
||||
internal Arena *async_root_thread_arena(ASYNC_Root *root);
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Work Thread Entry Point
|
||||
|
||||
|
||||
Reference in New Issue
Block a user