mirror of
https://github.com/RetroPortingToolKit/psxrecomp
synced 2026-10-26 02:11:36 -04:00
Experiment with CPU-copied overlay discovery
Co-authored-by: douglasjv <vanderveerdouglas@gmail.com>
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
# CPU-copied overlay discovery experiment
|
||||
|
||||
Source: [PSXRecomp PR #15](https://github.com/mstan/psxrecomp/pull/15),
|
||||
commit [`df7d1faa5f27be0ba357463a763c77efc43e1f91`](https://github.com/douglasjv/psxrecomp-tweaks/commit/df7d1faa5f27be0ba357463a763c77efc43e1f91).
|
||||
|
||||
This branch isolates the broad dispatch fallback used for overlays copied by
|
||||
guest CPU stores. It is experimental because any dispatch above the configured
|
||||
overlay floor becomes interpreter-eligible; the macOS GL and debug-input parts
|
||||
of the source commit are excluded.
|
||||
@@ -510,6 +510,10 @@ int dirty_ram_is_dirty(uint32_t phys) {
|
||||
if (phys >= RAM_SIZE) return 0;
|
||||
if (dirty_ram_force_interp() && phys >= DIRTY_RAM_KERNEL_TRACK_BYTES) return 1;
|
||||
if (dirty_ram_shellwin_interp() && phys >= 0x00030000u && phys <= 0x0005AFFFu) return 1;
|
||||
/* Experimental fallback for overlays copied into their final location by
|
||||
* ordinary guest CPU stores rather than CD DMA. Dispatch above the static
|
||||
* image floor is treated as dynamic and validated by the interpreter. */
|
||||
if (phys >= g_overlay_region_floor) return 1;
|
||||
uint32_t page = phys >> DIRTY_RAM_PAGE_SHIFT;
|
||||
return (dirty_ram_bitmap[page >> 5] >> (page & 31u)) & 1u;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user