diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2025-06-11 10:01:21 +0200 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2025-06-11 10:01:21 +0200 |
| commit | 5ebdab90eacd712a42eb5ddab8a4cfa8dd482323 (patch) | |
| tree | 48667ab5e5afe3dfb03d31cdaf35974d3b842478 /src/include | |
| parent | d1f8458f5887fe50b83060c30e0ee0ec0967157c (diff) | |
| download | box64-5ebdab90eacd712a42eb5ddab8a4cfa8dd482323.tar.gz box64-5ebdab90eacd712a42eb5ddab8a4cfa8dd482323.zip | |
[DYNACACHE] Dynarec memory is now part of MMpa file tracking when possible
Diffstat (limited to 'src/include')
| -rw-r--r-- | src/include/custommem.h | 5 | ||||
| -rw-r--r-- | src/include/env.h | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/src/include/custommem.h b/src/include/custommem.h index d7b79296..1ff4bdcc 100644 --- a/src/include/custommem.h +++ b/src/include/custommem.h @@ -31,9 +31,12 @@ size_t customGetUsableSize(void* p); #ifdef DYNAREC typedef struct dynablock_s dynablock_t; +typedef struct mmaplist_s mmaplist_t; // custom protection flag to mark Page that are Write protected for Dynarec purpose -uintptr_t AllocDynarecMap(size_t size); +uintptr_t AllocDynarecMap(uintptr_t x64_addr, size_t size); void FreeDynarecMap(uintptr_t addr); +mmaplist_t* NewMmaplist(); +void DelMmaplist(mmaplist_t* list); void addDBFromAddressRange(uintptr_t addr, size_t size); // Will return 1 if at least 1 db in the address range diff --git a/src/include/env.h b/src/include/env.h index ff8961c6..75eb0982 100644 --- a/src/include/env.h +++ b/src/include/env.h @@ -193,6 +193,8 @@ typedef struct box64env_s { uint64_t is_dynarec_perf_map_fd_overridden : 1; } box64env_t; +typedef struct mmaplist_s mmaplist_t; + void InitializeEnvFiles(); void ApplyEnvFileEntry(const char* name); const char* GetLastApplyEntryName(); @@ -204,5 +206,6 @@ void RemoveMapping(uintptr_t addr, size_t length); box64env_t* GetCurEnvByAddr(uintptr_t addr); int IsAddrFileMapped(uintptr_t addr, const char** filename, uintptr_t* start); size_t SizeFileMapped(uintptr_t addr); +mmaplist_t* GetMmaplistByAddr(uintptr_t addr); #endif // __ENV_H |