Texas Instruments MSP50C614 Stereo System User Manual


 
Individual Instruction Descriptions
4-176
4.14.80 SUBB Subtract Byte
Syntax
[label] name dest, src
Clock,
clk
Word,
w
With RPT,
clk
Class
SUBB A
n
,
imm8
1 1 N/R 2a
SUBB R
x
,
imm8
1 1 N/R 4b
Execution
dest
dest
imm8
PC PC + 1
Flags Affected
dest
is A
n
: OF, SF, ZF, CF are set accordingly
dest
is R
x
: RCF, RZF are set accordingly
Opcode
Instructions 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
SUBB A
n imm8
1 0 1 0 0 1 0 A
n imm8
SUBB R
x
,
imm8
1 0 1 1 0 1
k4 k3 k2 k7 k6 k5
R
x k1 k0
Description Subtract value of
src
byte from value of
dest
byte and store result in
dest
. Note
that subtraction is performed in 2’s complement and therefore the CF (carry
flag) may get set even when subtracting a smaller value from a larger value.
Syntax Description
SUBB A
n
,
imm8
Subtract immediate byte from A
n
SUBB R
x
,
imm8
Subtract immediate byte from R
x
Example 4.14.80.1 SUBB A2, 0x45
Subtract 0x45 from accumulator A2 byte.
Example 4.14.80.2 SUBB R3, 0xF2
Subtract 0xF2 from register R3 byte.