Musa-Cpp-Lib-V2/cpp_lib.todo

42 lines
2.5 KiB
Plaintext

[#TODO]
[ ] Context should include links to other living thread data (+ save dead threads in debug mode)
[ ] GetUnixTimestamp for timing and rdtsc for timing.
[ ] Thread primitives (Mutex, Semaphore, etc.)
[ ] Thread Creation / Deletion
[ ] Base layer and OS abstraction for Windows. (Ryan's Win32 platform layer is ~2k lines of code.)
- just implement the stuff we need
[ ] push_scratch() macro. (basically an auto_release_temp)
[ ] CreateWindow
[ ] ... Mouse / Keyboard inputs
[*] This is the order I want to follow, because I need them in thread context.
- Entry point(s) `Entry_Point_Main.cpp`
-> We can have a lib_init() instead of a clear entry point for now.
-> Switch from library to application once I add an entry point
-> See how rjf abstracts his entry points for each platform with TCTX.
[ ] 1. setup thread-local storage via thread_static (see raddbg, base_core.h,
C_LINKAGE thread_static TCTX *tctx_thread_local;
>> Must be assigned at entry point (arena_alloc())
>> TCTX defined in base_thread_context.h
> See Base_Thread.h
[Design Stuff]
[ ] "Primary Thread" <- Main entry point thread
[ ] "Secondary Thread" <- does all the heavy lifting for the first thread and synchronizes with the first.
[ ] Tertiary threads (launched by secondary thread and awaiting work as assigned by Primary and Secondary threads)
[ ] Multi-threaded by default with sync points
[ ] Need bindings for Semaphore and Mutex
[ ] Does calling SetProcessWorkingSetSize(.., -1, -1) cause the program to crash? Why tho.
[ ] Maybe we just shouldn't do this?
[ ] *our* program memory usage can be calculated by Stack Size + allocations from GPAllocator + allocations from arena.
[TODO - Low priority]
[ ] Fix implementation so all source is just in .cpp files (including templates), and auto-generate forward declares like Vjekoslav does.
[ ] Implement Secure Arenas (with VirtualLock, wiping memory with RtlSecureZeroMemory)
[ ] Way to serialize and deserialize settings in Text (I think using binary is a mistake here?).
[Project Ideas]
[ ](Graphics): How do I create a basic overlay that shows the time, date, cpu/gpu temps, frequency, memory usage all the time and responds to global hotkey to show more info
[Documentation Notes]
Main inspirations for this codebase:
(1) jonathan blow & jai compiler project
(2) casey muratori and "handmade" approach to software
(3) ryan fleury and raddebugger codebase
Always contemplate your impulses