SAL SHIFT ARITHMETIC LEFT SHL SHIFT LOGICAL LEFT

Operation:

Flags Affected:

(temp) +-- COUNT

CF, OF, PF, SF, ZF.

do while (temp) =1= 0

AF undefined

(CF) +-- high-order bit of (EA)

 

(EA) +-- (EA) * 2

 

(temp) +-- (temp)-1

 

if COUNT = 1 then

 

if high-order bit of (EA) =1= (CE)

 

then (OF) +--1

 

else (OF) +--0

 

else (OF) undefined

 

Description:

 

SHL/SAL destination, count

 

SHL and SAL (Shift Logical Left and Shift Arithmetic Left) perform the same operation and are physically the same instruction. The destination byte or word is shifted left by the number of bits specified in the count operand. Zeros are shifted in on the right. If the sign bit retains its original value, then OF is cleared.

SAL SHL

2-143

Page 178
Image 178
Intel 210200-002 manual SAL Shift Arithmetic Left SHL Shift Logical Left, Cf, Of, Pf, Sf, Zf