all repos — mgba @ 8e87e3a528941bc5104f28a1a94e6c7a4d820b5a

mGBA Game Boy Advance Emulator

GBA Memory: Fix I cycles that had been moved to ARM7 core
Jeffrey Pfau jeffrey@endrift.com
Fri, 27 Mar 2015 01:35:10 -0700
commit

8e87e3a528941bc5104f28a1a94e6c7a4d820b5a

parent

811ada598e2ba8595e114f5026328a95b2717bcd

1 files changed, 3 insertions(+), 3 deletions(-)

jump to
M src/gba/memory.csrc/gba/memory.c

@@ -380,7 +380,7 @@ break;

} if (cycleCounter) { - *cycleCounter += 2 + wait; + *cycleCounter += 1 + wait; } // Unaligned 32-bit loads are "rotated" so they make some semblance of sense int rotate = (address & 3) << 3;

@@ -483,7 +483,7 @@ break;

} if (cycleCounter) { - *cycleCounter += 2 + wait; + *cycleCounter += 1 + wait; } // Unaligned 16-bit loads are "unpredictable", but the GBA rotates them, so we have to, too. int rotate = (address & 1) << 3;

@@ -588,7 +588,7 @@ break;

} if (cycleCounter) { - *cycleCounter += 2 + wait; + *cycleCounter += 1 + wait; } return value; }