Class NEG

java.lang.Object
CPU.instructions.NEG
All Implemented Interfaces:
InstructionSet

public class NEG extends Object implements InstructionSet
The NEG instruction in all of its variants. 01000100ssmmmrrr = 4400 where rrr = data reg to be swapped
  • Constructor Details

    • NEG

      public NEG()
  • Method Details

    • register

      public final void register(MC68000Cpu cpu2)
      Description copied from interface: InstructionSet
      Registers the InstructionSet with the cpu.
      Specified by:
      register in interface InstructionSet
      Parameters:
      cpu2 - the cpu to use.
    • getDisplacement

      protected int getDisplacement(MC68000Cpu cpu)
      gets the displacement and increments the PC.
      Parameters:
      cpu - the smsqmulator.cpu.MC68000Cpu used.
      Returns:
      the displacement
    • disassembleOp

      protected final DisassembledInstruction disassembleOp(int address, int opcode, Size sz, MC68000Cpu cpu)