示例#1
0
 public Branch execute(Processor cpu) {
   cpu.flagOp1 = (byte) op1.get8(cpu);
   cpu.flagOp2 = (byte) immb;
   cpu.flagResult = (byte) (cpu.flagOp1 - cpu.flagOp2);
   cpu.flagIns = UCodes.SUB8;
   cpu.flagStatus = OSZAPC;
   return Branch.None;
 }
示例#2
0
 public Branch execute(Processor cpu) {
   Reg op1 = cpu.regs[op1Index];
   cpu.of = cpu.af = cpu.cf = false;
   cpu.flagResult = (byte) (op1.get8() ^ op2.get8(cpu));
   op1.set8((byte) cpu.flagResult);
   cpu.flagStatus = SZP;
   return Branch.None;
 }
示例#3
0
 public Branch execute(Processor cpu) {
   Reg op2 = cpu.regs[op2Index];
   int add = (cpu.cf() ? 1 : 0);
   cpu.flagOp1 = op1.get8(cpu);
   cpu.flagOp2 = op2.get8();
   cpu.flagResult = (byte) (cpu.flagOp1 - (cpu.flagOp2 + add));
   op1.set8(cpu, (byte) cpu.flagResult);
   cpu.flagIns = UCodes.SBB8;
   cpu.flagStatus = OSZAPC;
   return Branch.None;
 }
示例#4
0
 public Branch execute(Processor cpu) {
   op1.set8(cpu, (byte) ~op1.get8(cpu));
   return Branch.None;
 }