Motorola CPU32 Reference Manual page 178

Hide thumbs Also See for CPU32:
Table of Contents

Advertisement

ROL, ROR
Operation:
Assembler
Syntax:
Attributes:
Description:
The extend bit is not included in the rotation. For register rotation, the rotation count
can be specified in either of two ways:
1. Immediate — The count (1-8) is specified by the instruction.
2. Register — The count is the value in the data register specified by the instruc-
tion, modulo 64.
The size of the operation for register destinations is specified as byte, word, or long.
The contents of memory, 〈ea〉; can be rotated one bit only, and operand size is restrict-
ed to a word.
The ROL instruction rotates the bits of the operand to the left; the rotate count deter-
mines the number of bit positions rotated. Bits rotated out of the high-order bit go to
the carry bit and also back into the low-order bit.
The ROR instruction rotates the bits of the operand to the right; the rotate count deter-
mines the number of bit positions rotated. Bits rotated out of the low-order bit go to the
carry bit and also back into the high-order bit.
MOTOROLA
4-130
Rotate (Without Extend)
Destination Rotated by 〈count〉 → Destination
ROd Dx, Dy
ROd # 〈data〉, Dy
ROd 〈ea〉
where d is direction, L or R
Size = (Byte, Word, Long)
Rotates the bits of the operand in the direction specified (L or R).
ROL
ROR
INSTRUCTION SET
C
ROL, ROR
C
CPU32
REFERENCE MANUAL

Advertisement

Table of Contents
loading

Table of Contents