Exemplo n.º 1
0
 private static void TestIndex(PrefixCbOpCode op, OpCode expected, bool gameboy = true)
 {
     using (var fixture = new DecodeFixture(4, 15, PrimaryOpCode.Prefix_CB, op).ThrowOn8080().OnGameboy(gameboy))
     {
         fixture.Expected.OpCode(expected).Operands(Operand.mHL);
     }
 }
Exemplo n.º 2
0
        private static void TestZ80Index(PrefixCbOpCode op, Operand index, OpCode expected)
        {
            var displacement = Rng.SByte();

            using (var fixture = new DecodeFixture(6, 23, index.GetZ80IndexPrefix(), PrimaryOpCode.Prefix_CB, displacement, op).ThrowUnlessZ80())
            {
                fixture.Expected.OpCode(expected).Operands(index).Displacement(displacement);
            }
        }
Exemplo n.º 3
0
 public void SET_n_r(PrefixCbOpCode op, byte bit, Operand r) => Test(op, bit, r, OpCode.BitSet);
Exemplo n.º 4
0
 public void RES_n_r(PrefixCbOpCode op, byte bit, Operand r) => Test(op, bit, r, OpCode.BitReset);
Exemplo n.º 5
0
 public void BIT_n_r(PrefixCbOpCode op, byte bit, Operand r) => Test(op, bit, r, OpCode.BitTest, 3, 12);
Exemplo n.º 6
0
 public void RR_r_mIXYd(PrefixCbOpCode op, Operand r, Operand index) => TestZ80AutocopyIndex(op, index, r, index, OpCode.RotateRight);
Exemplo n.º 7
0
 public void RR_r(PrefixCbOpCode op, Operand r) => TestCb(op, r, OpCode.RotateRight);
Exemplo n.º 8
0
 public void RRC_r(PrefixCbOpCode op, Operand r) => TestCb(op, r, OpCode.RotateRightWithCarry);
Exemplo n.º 9
0
 public void SLS_r(PrefixCbOpCode op, Operand r) => TestCb(op, r, OpCode.ShiftLeftSet, false);
Exemplo n.º 10
0
 public void RLC_r_mIXYd(PrefixCbOpCode op, Operand r, Operand index) => TestZ80AutocopyIndex(op, index, r, index, OpCode.RotateLeftWithCarry);
Exemplo n.º 11
0
 public void SRL_r_mIXYd(PrefixCbOpCode op, Operand r, Operand index) => TestZ80AutocopyIndex(op, index, r, index, OpCode.ShiftRightLogical);
Exemplo n.º 12
0
 public void SRL_r(PrefixCbOpCode op, Operand r) => TestCb(op, r, OpCode.ShiftRightLogical);
Exemplo n.º 13
0
 public void SRA_r(PrefixCbOpCode op, Operand r) => TestCb(op, r, OpCode.ShiftRight);
Exemplo n.º 14
0
 public void SLS_r_mIXYd(PrefixCbOpCode op, Operand r, Operand index) => TestZ80AutocopyIndex(op, index, r, index, OpCode.ShiftLeftSet);
Exemplo n.º 15
0
 public void BIT_n_IXYd(Operand index, PrefixCbOpCode op, byte bit, Operand r) => Z80IndexTest(index, op, bit, r, OpCode.BitTest, 5, 20, false);
Exemplo n.º 16
0
 public void RL_r(PrefixCbOpCode op, Operand r) => TestCb(op, r, OpCode.RotateLeft);
Exemplo n.º 17
0
 public void SET_n_IXYd(Operand index, PrefixCbOpCode op, byte bit, Operand r) => Z80IndexTest(index, op, bit, r, OpCode.BitSet);
Exemplo n.º 18
0
 public void SLA_r(PrefixCbOpCode op, Operand r) => TestCb(op, r, OpCode.ShiftLeft);