SHAL (SHift Arithmetic Left)
SHAL
<Description>
This instruction shifts an 8-bit general register one bit to the left. The most significant bit
shifts into the carry flag, and the least significant bit is cleared to "0."
The operation is shown schematically below.
The SHAL instruction is identical to the SHLL instruction except for its effect on the overflow
(V) flag.
<Instruction Formats>
<Operation>
Rd (shifted arithmetic left )
→
Rd
<Assembly-Language Format>
SHAL
Rd
<Examples>
SHAL R5H
<Operand Size>
Byte
<Condition Code>
I: Previous value remains unchanged.
H: Previous value remains unchanged.
N: Set to "1" if the result is negative;
otherwise cleared to "0."
Z: Set to "1" if the result is zero; otherwise
cleared to "0."
V: Set to "1" if an overflow occurs;
otherwise cleared to "0."
C: Receives the previous value in bit 7.
I
H
N
Z
V
C
—
—
—
—
↕
↕
↕
↕
C
Bit 7
Bit 0
∧
∧
0
∧
MSB
LSB
Register direct
SHAL
Rd
1
0
8
rd
2
Addressing
mode
Mnem.
Operands
1st byte
Instruction code
No. of
states
2nd byte
3rd byte
4th byte
104
Содержание H8/300 Series
Страница 2: ...H8 300 Programming Manual...