ݺߣ

ݺߣShare a Scribd company logo
Assembly Language Programming
Chapter 9
The 8088 Instruction Set VI
Shift Instructions
SHL/SAL
Meaning Format Operation Flags Affected
Shift Logical Left/
Shift Arithmetic Left
SHL D, count
SAL D, count
Shift the
destination to the
left by the number
of bit positions
equal to Count
and fill the
vacated bits
positions on the
right with 0’s
CF, OF, PF, SF,
ZF
AF is undefined
SHR
Meaning Format Operation Flags Affected
Shift Logical Right SHR D, count Shift the
destination to the
right by the
number of bit
positions equal to
Count and fill the
vacated bits
positions on the
left with 0’s
CF, OF, PF, SF,
ZF
AF is undefined
SAR
Meaning Format Operation Flags Affected
Shift Arithmetic
Right
SAR D, count Shift the
destination to the
right by the
number of bit
positions equal to
Count and fill the
vacated bits
positions on the
left with the most
significant bit
CF, OF, PF, SF,
ZF
AF is undefined

More Related Content

Chapter 9 the 8088 instruction set vi - shift instructions

  • 1. Assembly Language Programming Chapter 9 The 8088 Instruction Set VI Shift Instructions
  • 2. SHL/SAL Meaning Format Operation Flags Affected Shift Logical Left/ Shift Arithmetic Left SHL D, count SAL D, count Shift the destination to the left by the number of bit positions equal to Count and fill the vacated bits positions on the right with 0’s CF, OF, PF, SF, ZF AF is undefined
  • 3. SHR Meaning Format Operation Flags Affected Shift Logical Right SHR D, count Shift the destination to the right by the number of bit positions equal to Count and fill the vacated bits positions on the left with 0’s CF, OF, PF, SF, ZF AF is undefined
  • 4. SAR Meaning Format Operation Flags Affected Shift Arithmetic Right SAR D, count Shift the destination to the right by the number of bit positions equal to Count and fill the vacated bits positions on the left with the most significant bit CF, OF, PF, SF, ZF AF is undefined