![Page 1: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/1.jpg)
UNIT-1 REGISTER TRANSFER AND MICROOPERATIONS
1
![Page 2: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/2.jpg)
2
1.1 Overview of computers and basics of Digital
Electronics-Flip Flops, Registers, Shift registers
1.2 Register - Transfer-Language
1.3 Register Transfer
1.4 Bus Transfer and Memory Transfer
1.5 Arithmetic Micro-Operations
Addition, Subtraction, Complements, Negation,
Increment and Decrement
1.6 Logic micro operations
1.7 Shift Micro operation.
1.8 Arithmetic Logic Shift Unit
SYLLABUS
![Page 3: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/3.jpg)
1.1 OVERVIEW OF COMPUTERS AND BASICS OF
DIGITAL ELECTRONICS-FLIP FLOPS,
REGISTERS, SHIFT REGISTERS
It is an interconnection of digital modules.
It is a system that manipulates discrete elements of
information that is represented internally in a binary
form.
Advantages:
Easy to Design
Low Cost
Very Fast Speed
More Popular with upgrading Technology
Easy to Function
Easy to Program3
![Page 4: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/4.jpg)
BLOCK DIAGRAM OF DIGITAL COMPUTERS
ALU
Control Unit
Input Unit
OutPutUnit
MemoryUnit
• KeyBoard• Mouse
• Monitor• Printer
4
![Page 5: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/5.jpg)
FLIP FLOP
It can store 1-bit information.
It can be designed using NAND or NOR gates.
It has to stable states: Logic 1 and Logic 0
Types Of Flip Flop
RS Flip Flop
D Flip Flop
T Flip Flop
JK Flip Flop
Master Slave JK Flip Flop
Application Of Flip Flop
Used as a memory element
Used as a delay element
Used as a basic block in counters and registers5
![Page 6: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/6.jpg)
1.2 REGISTERS- TRANSFER LANGUAGE
R1
Processor Register R
Numbering of bits
Showing individual bits
Subfields
PC(H) PC(L)
15 8 7 0
• Common ways of drawing the block diagram of a register
7 6 5 4 3 2 1 0
PC
15 0
oDenoted by capital letters oMemory Address Register(MAR)oProgram Counter(PC)oInstruction Register(IR)oProcessor Register(PR)
6
![Page 7: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/7.jpg)
BLOCK DIAGRAM OF REGISTER TRANSFER
Implementation of controlled transfer
P: R2 R1
Block diagram
Timing diagram
Clock
Transfer occurs here
R2
R1
Control Circuit LoadP
n
Clock
Load
t t+1
7
![Page 8: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/8.jpg)
1.3 REGISTER AND SHIFT REGISTER
To increase the storage capacity, we use a group of
flip flops. This group of flip flop is known as a
Register.
Shift Register is used for storage and transfer of
digital data.
Types of Shift Register
Serial IN Serial Out
Serial In Parallel Out
Parallel In Serial Out
Parallel In Parallel Out8
![Page 9: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/9.jpg)
1.4 BUS AND MEMORY TRANSFER
o Bus is a path(of a group of wires) over which
information is transferred, from any of several
sources to any of several destinations.
o A bus structure consists of a set of common lines, one
for each bit of a register, through which binary
information is transferred one at a time.
o Control signal determine which register is selected by
the bus.
9
![Page 10: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/10.jpg)
BUS AND BUS TRANSFER (USING MULTIPLEXERS)
10
![Page 11: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/11.jpg)
CONTINUE…
Function Table
S1 S0 Register Selected
0 0 A
0 1 B
1 0 C
1 1 D
11
![Page 12: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/12.jpg)
THREE-STATE BUS BUFFERS
Three state gate is digital circuit that exhibits three states. Logic 1,Logic 0 and High Impedance state.
12
![Page 13: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/13.jpg)
USING TRI STATE BUFFER GATES
Bus line with three-state buffers
Select
Enable
0123
S0
S1
A0
B0
C0
D0
Bus line for bit 0
• When the enable input of the decoder is 0, all of its four outputs are 0, bus line is in high impedance state.
• When the enable input of the decoder is 1,one of the four buffer will be active, depending on the selection value.
13
![Page 14: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/14.jpg)
BUS LINE WITH THREE-STATE BUFFERS
Function Table
S1 S0 Register Selected
0 0 Tri State buffer gates for Register A Enable
0 1 Tri State buffer gates for Register B Enable
1 0 Tri State buffer gates for Register C Enable
1 1 Tri State buffer gates for Register D Enable
14
![Page 15: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/15.jpg)
MEMORY TRANSFER
Two Types of transfer operation
Memory Read
Memory Write
Address Register(AR) : Memory Unit that
receives the address from register
Data Register(DR): Data are transferred to
register.
15
![Page 16: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/16.jpg)
MEMORY TRANSFER
Memory Read
The transfer of information into DR from
the Memory Word M selected by the address AR.
Read: DR <---- M[AR]
Memory Write
The transfer of New information to be
stored into the memory is called a write operation.
Write: M[AR] <---R116
![Page 17: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/17.jpg)
1.5 ARITHMETIC MICRO OPERATIONS
The operations executed on data stored in
registers.
Example: Shift,Load,Clear,Increment
R3 R1+ R2 (ADD)
R3 R1 –R2 (Sub)
R2 R2’ (1’s complement of R2)
R2 R2’ + 1 (2’s complement of R2)
R3 R1+ R2’ +1 (Subtraction)
R1 R1 +1 Increment by 1
R1 R1 -1 Decrement by 117
![Page 18: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/18.jpg)
BINARY ADDER
FA
B0 A0
S0
C0FA
B1 A1
S1
C1FA
B2 A2
S2
C2FA
B3 A3
S3
C3
C4
18
![Page 19: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/19.jpg)
BINARY ADDER - SUBTRACTOR
FA
B0 A0
S0
C0C1FA
B1 A1
S1
C2FA
B2 A2
S2
C3FA
B3 A3
S3C4
M
B M O/P
0 0 0
0 1 1
1 0 1
1 1 0
When M=0 the circuit is ADDER.
When M=1 the circuit becomes Subtractor.
19
![Page 20: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/20.jpg)
BINARY INCREMENTER
HA
x y
C S
A0 1
S0
HA
x y
C S
A1
S1
HA
x y
C S
A2
S2
HA
x y
C S
A3
S3C4
One of the inputs to the least Significant Half Adder is connected to Logic 1and other input is connected to the LSB of the number to be incremented.
20
![Page 21: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/21.jpg)
ARITHMETIC CIRCUIT
S1S00123
4x1MUX
X0
Y0
C0
C1
D0FA
S1S00123
4x1MUX
X1
Y1
C1
C2
D1FA
S1S00123
4x1MUX
X2
Y2
C2
C3
D2FA
S1S00123
4x1MUX
X3
Y3
C3
C4
D3FA
Cout
A0
B0
A1
B1
A2
B2
A3
B3
0 1
S0S1Cin
S1 S0 Cin Y Output Microoperation
0 0 0 B D = A + B Add
0 0 1 B D = A + B + 1 Add with carry
0 1 0 B’ D = A + B’ Subtract with borrow
0 1 1 B’ D = A + B’+ 1 Subtract
1 0 0 0 D = A Transfer A
1 0 1 0 D = A + 1 Increment A
1 1 0 1 D = A - 1 Decrement A
1 1 1 1 D = A Transfer A
21
![Page 22: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/22.jpg)
1.6 LOGIC MICROOPERATIONS
Specify binary operations on the strings of bits in
registers
o Logic microoperations are bit-wise operations, i.e.,
they work on the individual bits of data
o useful for bit manipulations on binary data
o useful for making logical decisions based on the
bit value
16 different logic functions that can be defined over
two binary input variables
most systems only implement four of these
AND ()
OR (),
XOR ()
Complement/NOT
22
![Page 23: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/23.jpg)
LIST OF LOGIC MICROOPERATIONSBoolean Function Micro operations Logic Function
F0=0 F0 Clear
F1=x FA Transfer A
F2=y FB Transfer B
F3=x.y FA /\ B AND
F4=x+y FA\/ B OR
F5=(xy)’ F A /\ B NAND
F6=(x+y)’ FA\/ B NOR
F7=x y FA B EX-OR
F8= (x y)’ FA B EX-NOR
F9=x’ FA’ Complement A
F10=y’ FB’ Complement B
F11=x.y’ FA /\ B’
F12=x’.y FA ‘/\ B
23
![Page 24: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/24.jpg)
F13=x’+y FA’\/ B
F14=x+y’ FA\/ B’
F15=1 F1 Set to all 1
24
![Page 25: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/25.jpg)
SELECTIVE SET
Operation set to 1 bits in register A where there
are corresponding 1’s in register B.
The OR- Micro operation can be used to
selectively set bits of a register
1 1 0 0 At
1 0 1 0 B
1 1 1 0 At+1 (A A + B)
APPLICATION OF LOGIC MICRO OPERATION
25
![Page 26: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/26.jpg)
SELECTIVE COMPLEMENT
Complement bits in A where there are
corresponding 1’s in B.
Exclusive OR microoperation can be used For
Selective Complement
1 1 0 0 At
1 0 1 0 B
0 1 1 0 At+1 (A A B)
26
![Page 27: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/27.jpg)
SELECTIVE CLEAR
Clear to 0 in bits of A where there are
corresponding 1’s in B.
Logic Micro operation is: AA/\B’
1 1 0 0 At
1 0 1 0 B
0 1 0 0 At+1 (A A B’)
27
![Page 28: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/28.jpg)
MASK OPERATION
It is similar to selective CLEAR except that the bits
of A are cleared only where there are corresponding
0’s in B
1 1 0 0 At
1 0 1 0 B
1 0 0 0 At+1 (A A B)
28
![Page 29: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/29.jpg)
CLEAR OPERATION
It compares the words in A and B and if two
numbers are equal then produces 0’s.
1 0 1 0 At
1 0 1 0 B
0 0 0 0 At+1
29
![Page 30: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/30.jpg)
INSERT OPERATION
Insert operation inserts a new value into a group of
bits.
This is done by first masking the bits and then
Oring them with the required value.
Example
A 0 1 1 0 1 0 1 0
B 0 0 0 0 1 1 1 1 Mask
0 0 0 0 1 0 1 0 After Masking
And then insert a new value
A 0 0 0 0 1 0 1 0 Before
B 1 0 0 1 0 0 0 0 Insert
A 1 0 0 1 1 0 1 0 After Insertion
30
![Page 31: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/31.jpg)
1.7 SHIFT MICROOPERATIONS
There are three types of shifts
Logical shift
Circular shift
Arithmetic shift
Serialinput
• A right shift operation
• A left shift operationSerialinput
31
![Page 32: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/32.jpg)
LOGICAL SHIFT
In a logical shift the serial input to the shift is a
0.
A right logical shift operation:
A left logical shift operation:
0
0
32
![Page 33: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/33.jpg)
CIRCULAR SHIFT
In a circular shift the serial input is the bit that is shifted out of the other end of the register.
A right circular shift operation:
A left circular shift operation:
In a RTL, the following notation is used
cil for a circular shift left
cir for a circular shift right
Examples:
R2 cir R2
R3 cil R3
33
![Page 34: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/34.jpg)
ARITHMETIC SHIFT
An arithmetic shift is meant for signed binary
numbers
An arithmetic left shift multiplies a signed number
by two
An arithmetic right shift divides a signed number by
two
A right arithmetic shift operation:
A left arithmetic shift operation:
signbit
signbit
34
![Page 35: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/35.jpg)
1.8 ARITHMETIC LOGIC SHIFT UNIT
35
![Page 36: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/36.jpg)
S3 S2 S1 S0 Cin Operati
on
Function
0 0 0 0 0 F=A Transfer A
0 0 0 0 1 F=A+1 Increment A
0 0 0 1 0 F=A+B Addition
0 0 0 1 1 F=A+B+1 Addition with
Carry
0 0 1 0 0 F=A+B’ Subtraction with
borrow
0 0 1 0 1 F=A+B’+
1
Subtraction
0 0 1 1 0 F=A-1 Decrement A
0 0 1 1 1 F=A Transfer A
0 1 0 0 -- F=A /\B AND
36
![Page 37: REGISTER TRANSFER AND MICROOPERATIONS2 1.1 Overview of computers and basics of Digital Electronics-Flip Flops, Registers, Shift registers 1.2 Register - Transfer-Language 1.3 Register](https://reader036.vdocuments.mx/reader036/viewer/2022081411/60aca2c83337f14b7f4afd1c/html5/thumbnails/37.jpg)
37
0 1 0 1 -- F=A\/ B OR
0 1 1 0 -- F = A B EX-OR
0 1 1 1 -- F=A’ COMPLE
MENT A
1 0 -- -- -- F=shr A Shift
Right
1 1 -- -- -- F= shl A Shift Left