Intel 80C188XL User Manual

Page 359

Advertising
background image

INSTRUCTION SET DESCRIPTIONS

C-36

RCL

Rotate Through Carry Left:

RCL

dest, count

Rotates the bits in the byte or word
destination operand to the left by the
number of bits specified in the count
operand. The carry flag (CF) is treated
as "part of" the destination operand;
that is, its value is rotated into the low-
order bit of the destination, and itself is
replaced by the high-order bit of the
destination.

Instruction Operands:

RCL reg, n
RCL mem, n
RCL reg, CL
RCL mem, CL

(temp)

count

do while (temp)

0

(tmpcf)

(CF)

(CF)

high-order bit of (dest)

(dest)

(dest) × 2 + (tmpcf)

(temp)

(temp) – 1

if

count = 1

then

if

high-order bit of (dest)

(CF)

then

(OF)

1

else

(OF)

0

else

(OF) undefined

AF –
CF

ü

DF –
IF –
OF

ü

PF –
SF –
TF –
ZF –

RCR

Rotate Through Carry Right:

RCR dest, count

Operates exactly like RCL except that
the bits are rotated right instead of left.

Instruction Operands:

RCR reg, n
RCR mem, n
RCR reg, CL
RCR mem, CL

(temp)

count

do while (temp)

0

(tmpcf)

(CF)

(CF)

low-order bit of (dest)

(dest)

(dest) / 2

high-order bit of (dest)

(tmpcf)

(temp)

(temp) – 1

if

count = 1

then

if

high-order bit of (dest)

next-to-high-order bit of (dest)

then

(OF)

1

else

(OF)

0

else

(OF) undefined

AF –
CF

ü

DF –
IF –
OF

ü

PF –
SF –
TF –
ZF –

Table C-4. Instruction Set (Continued)

Name

Description

Operation

Flags

Affected

NOTE:

The three symbols used in the Flags Affected column are defined as follows:
– the contents of the flag remain unchanged after the instruction is executed
? the contents of the flag is undefined after the instruction is executed

ü

the flag is updated after the instruction is executed

Advertising
This manual is related to the following products: