diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2023-04-20 22:59:03 +0200 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2023-04-20 22:59:13 +0200 |
| commit | ae08d21bf12fbefa5a7531cf7b61ea5ba9620bae (patch) | |
| tree | ad91f296847159352ab23932fd04a1a93930e3ad /src | |
| parent | 5f69e58f3743c12e68691373421c893b367076ef (diff) | |
| download | box64-ae08d21bf12fbefa5a7531cf7b61ea5ba9620bae.tar.gz box64-ae08d21bf12fbefa5a7531cf7b61ea5ba9620bae.zip | |
[DYNAREC] Fixed an optimisation in getDBSize helper function
Diffstat (limited to 'src')
| -rw-r--r-- | src/custommem.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/custommem.c b/src/custommem.c index 45c7a01f..f77b005c 100644 --- a/src/custommem.c +++ b/src/custommem.c @@ -590,6 +590,7 @@ static uintptr_t getDBSize(uintptr_t addr, size_t maxsize, dynablock_t** db) uintptr_t* block = box64_jmptbl3[idx3][idx2][idx1]; if(block == box64_jmptbldefault0) return (((addr>>JMPTABL_START1)+1)<<JMPTABL_START1); + maxsize+=idx0; // need to adjust maxsize to "end in current block" if (maxsize>JMPTABLE_MASK0) maxsize = JMPTABLE_MASK0; while(block[idx0]==(uintptr_t)native_next) { |