Class ADDI

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

public class ADDI extends Object implements InstructionSet
The ADDI instruction in all of its variants. fedcba9876543210 00000110ssmmmrrr = 600 where rrr = reg for ea ss = size mmm = mode
  • Constructor Details

    • ADDI

      public ADDI()
  • 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 final int getDisplacement(MC68000Cpu cpu)
      Gets the displacement and increments the PC.
      Parameters:
      cpu - the smsqmulator.cpu.MC68000Cpu used the cpu used.
      Returns:
      the displacement.
    • disassembleOp

      protected final DisassembledInstruction disassembleOp(int address, int opcode, Size sz, MC68000Cpu cpu)
      Disassemble the instruction.
      Parameters:
      address - address of op in memory
      opcode - MC68000 opcode of operation
      sz - size (.b, .w, .l)
      cpu - cpu used
      Returns:
      the DisassembledInstruction