Unify Intel style JR CC code and fix SM83 timing issues.

This commit is contained in:
Adrian Conlon
2025-05-03 12:09:34 +01:00
parent 0679b95b77
commit 080f203a55
3 changed files with 2 additions and 23 deletions

View File

@@ -173,13 +173,11 @@ namespace EightBit
protected virtual bool JumpRelativeConditional(bool condition)
{
this.Intermediate.Assign(this.PC);
++this.PC.Word;
var offset = this.FetchByte();
if (condition)
{
this.JumpRelative(this.MemoryRead(this.Intermediate));
this.JumpRelative(offset);
}
return condition;
}

View File

@@ -354,15 +354,6 @@ namespace LR35902
return base.ReturnConditional(condition);
}
protected override bool JumpRelativeConditional(bool condition)
{
if (!base.JumpRelativeConditional(condition))
{
this.MemoryRead(this.PC);
}
return condition;
}
protected override void Return()
{
base.Return();

View File

@@ -563,16 +563,6 @@ namespace Z80
this.Tick(5);
}
protected override bool JumpRelativeConditional(bool condition)
{
var offset = this.FetchByte();
if (condition)
{
this.JumpRelative(offset);
}
return condition;
}
private int Zero()
{
return ZeroTest(this.F);