mirror of
https://github.com/holub/mame
synced 2025-04-20 23:42:22 +03:00
![]() Here is a fix I've done to the Z80 CPU core that removes the increasing of the R register from each IX/IY related (FD xx or DD xx) instruction. This corrects the amount the R register should increased to to 2, instead of 3. Documentation I've read suggests that the R register is increased by 1 for each instruction with no prefix, and by 2 for each instruction with a prefix (DD, FD, ED, CB, DD CB and FD CB). This fixes some protected cassette loaders in the MESS Amstrad CPC driver, and maybe others, which require the R register to be correct for the next routine to be decoded correctly. I'd doubt that there is much, if any, noticeable impact for MAME, as the R register is really only useful to a program as a simple random number generator (or seed). I've tested the fix with Pacman, in MAME, and when it comes across a LD IX,xxxx or ADD IX,xx it will increase R by 2, whereas previously, it increased R by 3. |
||
---|---|---|
docs | ||
src | ||
.gitattributes | ||
makefile |