mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-07-14 13:31:25 -07:00
extend artifact cache with non-key-included generations, to allow gracefully decaying certain computations
This commit is contained in:
@@ -17,6 +17,7 @@ typedef struct AC_Request AC_Request;
|
||||
struct AC_Request
|
||||
{
|
||||
String8 key;
|
||||
U64 gen;
|
||||
AC_CreateFunctionType *create;
|
||||
};
|
||||
|
||||
@@ -33,8 +34,9 @@ struct AC_Node
|
||||
AC_Node *next;
|
||||
AC_Node *prev;
|
||||
|
||||
// rjf: key/value
|
||||
// rjf: key/gen/value
|
||||
String8 key;
|
||||
U64 gen;
|
||||
void *val;
|
||||
|
||||
// rjf: metadata
|
||||
@@ -94,7 +96,7 @@ internal void ac_init(void);
|
||||
////////////////////////////////
|
||||
//~ rjf: Cache Lookups
|
||||
|
||||
internal void *ac_artifact_from_key(Access *access, String8 key, AC_CreateFunctionType *create, AC_DestroyFunctionType *destroy, U64 slots_count);
|
||||
internal void *ac_artifact_from_key(Access *access, String8 key, U64 gen, AC_CreateFunctionType *create, AC_DestroyFunctionType *destroy, U64 slots_count);
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Tick
|
||||
|
||||
Reference in New Issue
Block a user