From f73e4193f032713529e26c4537e5fac44147c040 Mon Sep 17 00:00:00 2001 From: ptitSeb Date: Fri, 5 Nov 2021 21:17:14 +0100 Subject: Chnaged memory protection tracking to reduce usage of lock, especially for [DYNAREC] reduced mutrex and chances of deadlock (help RimWorld) --- src/include/custommem.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/include') diff --git a/src/include/custommem.h b/src/include/custommem.h index 4e4ff6b4..156d0c11 100644 --- a/src/include/custommem.h +++ b/src/include/custommem.h @@ -45,10 +45,8 @@ uint32_t getProtection(uintptr_t addr); void loadProtectionFromMap(); #ifdef DYNAREC void protectDB(uintptr_t addr, size_t size); -void protectDBnolock(uintptr_t addr, size_t size); void unprotectDB(uintptr_t addr, size_t size); -void lockDB(); -void unlockDB(); +int isprotectedDB(uintptr_t addr, size_t size); #endif void* find32bitBlock(size_t size); void* findBlockNearHint(void* hint, size_t size); -- cgit 1.4.1