4/17/98 6-155 Addressing Modes and Data Types
SUB Integer Subtract
Syntax: SUB dest, src
Operation: dest <- dest - src
Description: Performs a twos complement binary subtraction of the source and destination
operands, and the result is placed in the destination operand. The source data is not affected by the
operation.
Size: Byte-Byte, Word-Word
Flags Updated: C, AC, V, N, Z
SUB Rd, Rs
Bytes: 2
Clocks: 3
Operation: (Rd) <-- (Rd) - (Rs)
Encoding:
SUB Rd, [Rs]
Bytes: 2
Clocks: 4
Operation: (Rd) <-- (Rd) - ((WS:Rs))
Encoding:
SUB [Rd], Rs
Bytes: 2
Clocks: 4
Operation: ((WS:Rd)) <-- ((WS:Rd)) - (Rs)
Encoding:
0 0 1 0 SZ 0 0 1 d d d d s s s s
0 0 1 0 SZ 0 1 0 d d d d 0 s s s
0 0 1 0 SZ 0 1 0 s s s s 1 d d d