Rotate and shift – Zilog Z08470 User Manual
Page 63

UM008007-0715
Rotate and Shift
Z80 CPU
User Manual
51
Rotate and Shift
A major feature of the Z80 CPU is to rotate or shift data in the Accumulator, any general-
purpose register, or any memory location. All of the Rotate and Shift op codes are
depicted in Figure 39. Also included in the Z80 CPU are arithmetic and logical shift oper-
ations. These operations are useful in a wide range of applications including integer multi-
plication and division. Two BCD digit rotate instructions (RRD and RLD) allow a digit in
the Accumulator to be rotated with the two digits in a memory location pointed to by reg-
ister pair HL. These instructions allow for efficient BCD arithmetic.