Subx (Subtract With Extend Carry) - Renesas H8/300 Series Programming Manual

Table of Contents

Advertisement

SUBX (SUBtract with eXtend carry)

<Operation>
Rd – (EAs) – C → Rd
<Assembly-Language Format>
SUBX <EAs>, Rd
<Examples>
SUBX R0L, R3L
SUBX #H'32, R5H
<Operand Size>
Byte
<Description>
This instruction subtracts the source operand and carry flag from the contents of an 8-bit
general register and places the result in the general register.
The source operand can be an 8-bit register value or immediate byte data.
<Instruction Formats>
Addressing
mode
Immediate
Register direct
Mnem.
Operands
SUBX
#xx:8, Rd
SUBX
Rs, Rd
<Condition Code>
I
— —
I: Previous value remains unchanged.
H: Set to "1" if there is a borrow from bit 3;
otherwise cleared to "0."
N: Set to "1" when the result is negative;
otherwise cleared to "0."
Z: Previous value remains unchanged when
the result is zero; otherwise cleared to
"0."
V: Set to "1" if an overflow occurs;
otherwise cleared to "0."
C: Set to "1" if there is a borrow from bit 7;
otherwise cleared to "0."
Instruction code
1st byte
2nd byte
B
rd
IMM
1
E
rs
rd
114
H
N
Z
3rd byte
4th byte
SUBX
V
C
No. of
states
2
2

Advertisement

Table of Contents
loading

Table of Contents