Download CPU32 Reference Manual [330 pages!]
Transcript
SUB SUB Subtract Destination – Source → Destination Operation: Assembler SUB 〈ea〉, Dn Syntax: SUB Dn, 〈ea〉 Attributes: Size = (Byte, Word, Long) Description: Subtracts the source operand from the destination operand and stores the result in the destination. The mode of the instruction indicates which operand is the source, which is the destination, and which is the operand size. Condition Codes: X N Z V C * * * * * X N Z V C Set to the value of the carry bit. Set if the result is negative. Cleared otherwise. Set if the result is zero. Cleared otherwise. Set if an overflow is generated. Cleared otherwise. Set if a borrow is generated. Cleared otherwise. 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 EFFECTIVE ADDRESS 1 1 0 1 REGISTER OPMODE MODE REGISTER Instruction Fields: Register field — Specifies any of the eight data registers. Opmode field: Byte 000 100 MOTOROLA 4-144 Word 001 101 Long 010 110 INSTRUCTION SET Operation (〈ea〉) – (〈Dn〉) → 〈Dn〉 (〈Dn〉) – (〈ea〉) → 〈ea〉 CPU32 REFERENCE MANUAL