10/26/2014
1
Computer Organization
Instructors :
Dr. Abdul Raouf Khan
Mr.Marwan El-Haj
Shift Microoperations
Shift Microoperations are used for serial transfer of
data. They are also used with arithmetic, logical and
other data processing units. The contents of a
register can be shifted to the left or right, with the flip
Flops receiving data from serial inputs.
10/26/2014
2
Types of Shift Microoperations
There are three types of Shifts
1) Logical shift
2) Circular shift
3) Arithmetic shift
1. Logical shift
A logical Shift transfers ‘0’ through the serial
input and bits are shifted one bit to the left or
right. A logical shift (shl) transfers ‘0’ in bit
position R0 and right shift (shr) transfers ‘0’
in bit position Rn-1.
10/26/2014
3
2. circular shift
A circular Shift (also called a rotate operation)
circulates the bits of the register around the
two ends. The serial output is connected to the
serial input. The shift can be left (cil) or right
(cir).
3. Arithmetic shift
An arithmetic shift, shifts a signed binary number to
the left or right.
The arithmetic shift right (ashr) leaves the sign bit
unchanged and shifts the number (including the sign
bit) to the right. Rn-1 remains the same. R0 is lost
The arithmetic shift left (ashl) inserts a ‘0’ into R0 and
shifts all other bits to the left. A sign change takes
place if Rn-1 changes value, this is due to overflow ( if
Rn-1 Rn-2=1)
10/26/2014
4
Assignment 4
Draw the logic circuit for the 6 shift Micro
operations Considering Register A Size of 4
bits.
Bonus Point will be given for the student who
add the part of overflow detection(either
before or after occuring)
Bidirectional shift register with parallel load
10/26/2014
5
Bidirectional shift register with parallel load
4-Bit Combinational Circuit Shifter
Function Table
Select Output
S H3 H2 H1 H0
0 A2 A1 A0 IR
1 IL A3 A2 A1
10/26/2014
6
Arithmetic Logical Shift Unit

Lect4 organization

  • 1.
    10/26/2014 1 Computer Organization Instructors : Dr.Abdul Raouf Khan Mr.Marwan El-Haj Shift Microoperations Shift Microoperations are used for serial transfer of data. They are also used with arithmetic, logical and other data processing units. The contents of a register can be shifted to the left or right, with the flip Flops receiving data from serial inputs.
  • 2.
    10/26/2014 2 Types of ShiftMicrooperations There are three types of Shifts 1) Logical shift 2) Circular shift 3) Arithmetic shift 1. Logical shift A logical Shift transfers ‘0’ through the serial input and bits are shifted one bit to the left or right. A logical shift (shl) transfers ‘0’ in bit position R0 and right shift (shr) transfers ‘0’ in bit position Rn-1.
  • 3.
    10/26/2014 3 2. circular shift Acircular Shift (also called a rotate operation) circulates the bits of the register around the two ends. The serial output is connected to the serial input. The shift can be left (cil) or right (cir). 3. Arithmetic shift An arithmetic shift, shifts a signed binary number to the left or right. The arithmetic shift right (ashr) leaves the sign bit unchanged and shifts the number (including the sign bit) to the right. Rn-1 remains the same. R0 is lost The arithmetic shift left (ashl) inserts a ‘0’ into R0 and shifts all other bits to the left. A sign change takes place if Rn-1 changes value, this is due to overflow ( if Rn-1 Rn-2=1)
  • 4.
    10/26/2014 4 Assignment 4 Draw thelogic circuit for the 6 shift Micro operations Considering Register A Size of 4 bits. Bonus Point will be given for the student who add the part of overflow detection(either before or after occuring) Bidirectional shift register with parallel load
  • 5.
    10/26/2014 5 Bidirectional shift registerwith parallel load 4-Bit Combinational Circuit Shifter Function Table Select Output S H3 H2 H1 H0 0 A2 A1 A0 IR 1 IL A3 A2 A1
  • 6.