Vous êtes sur la page 1sur 18

DIGITAL ELECTRONICS

Registers Transfer Logic and


Micro-operation
Introduction
A Digital system can be described using higher level
functional blocks like adder, decoder and resister.
The resister transfer logic is a higher level
mathematical notation. It can be used to describe
digital system.
Resister transfer logic has a set of expressions and
statement. These statement can be use to describe
the various operation performed on data stored in
resisters.
Register Transfer Logic
Information stored in one register can be transferred can be
transferred to another register.
A Register consists of cells.
The cell S or flip-flops of an n-bit register are numbered in
siquence from 0 to n-1.
A Register transfer operation may be designed as:
R1 R2
Means, transfer contents of register R2 into R1
The control variable is terminated with a colon.
It indicates that the transfer will take place when C = 1.
Register Transfer Language
It is a symbolic notation for representing register, for
specifying operation on the contents of register, and for
specifying control functions.
In most of the digital system, there is a set of registers.
These registers are used for storing of data.
The sequence of micro-operations on these register is fixed.
A machine instruction is executed by issuing a sequence of
control functions.
A statement in a register-transfer language consists of a
control function and a list of micro-operations.
The control function specifies the control condition and
timing sequence for executing the listed micro-operations.
Register Transfer Language
These micro-operations can be classified into four
categories:
Inter register-transfer: Information moves one register to
another.
Arithmetic : Arithmetic operation is performed on
numbers stored in registers.
Logic : Logic operation (Like AND, OR, NOT etc.) is
performed on information stored in registers.
Shift : Micro-operations specify operations for shift
registers.
Fixed Point Representation
In the fixed point numbers we assume that the position
of the binary point is at the end.
It implies that all integers are represented using fixed
point representation.
Sign magnitude representation :
0 for positive

1 for Negative 1 bit sign n bits magnitude

(n + 1) bit number
Sign magnitude representation

The sign of the number is represented using the left most


bit.
The left most bit is 0 for positive numbers and 1 for
negative numbers.
Thus, a number of n bits can be represented as n + 1 bit
number, where (n + 1)th bit is the sign bit and reset n bits
represent its magnitude.
Overflow

An overflow occurs when two numbers are added and the


result cannot be accommodated in the destination register.
An overflow cannot occur if the numbers to be added are of
different sign, result will be smaller than the larger of the
two numbers.
When two numbers in sign-magnitude representation are
added, overflow can be detected from the carry out.
Overflow
When two numbers using 2s compliment representation are added, overflow


occurs if the carry into the sign bit is not equal to carry iut if the sign-bit.
i.e. Cn 1 O Cn = 0 [ For no overflow]

carry into the sign bit carry out of the sign-bit


Fig.2.Overflow in addition of 2s-Comp. numbers

Xn - 1 Registor X0

Cn
F/A Adder
0

Cn - 1 Xn 1
1- overflow Yn - 1
Registor
Y0
Accumulation
0- no overflow
Arithmetic shifts

An Arithmetic shift operation shifts a signed number to the


left or right.
An Arithmetic shift left operation multiplies a signed binary
number by 2.
An Arithmetic shift right operation divides a signed binary
number by 2.
In sign magnitude representation, the sign bit does not
participate in shifting.
Arithmetic shifts
Number Z +13

Representation = 0 1101

After left shift = 0 1101 0 => 0 1010

0 1101 0 0110
After right shift= =>
0
Floating Point Numbers
The range of numbers that can be represented by a fixed-
point number is insufficient for many applications.
In Scientific applications, very large and very small
numbers are encountered.
Scientific notation permits us to represent such numbers
using relatively few digits.
For e.g. 2.5 1010
Represent a fixed point integer 25000000000.
The floating-point codes used in computers are represented
in binary.
Floating Point Numbers
Format of representation :
Three numbers are associated with a floating point number:
1. A mantissa (M)
2. An exponent (E)
3. Base (B)
The mantissa M is also referred to as the significant or fraction.
These three components together represent the real number.

Exponent
M BE
Mantissa Base
Floating Point Numbers
For e.g.,
in 2.5 1010

Mantissa = 2.5
Exponent = 10
Base = 10
Instruction Codes
Every digital computer has a fixed set of instructions.
A program is a set of instructions.
The control reads each instruction from memory and place
it in a control register.
The control then interprets the instruction and executes it
by issuing a sequence of control functions.
A instruction code is a group of bits that the computer to
perform a specific operation.
An instruction code is divided into parts, each part has its
own interpretation.
Instruction Codes
(a) Implied

Operation-Code

(b)Immediate operand
Operation-Code Operand

(c)Direct address
Operation-Code Address of Operand
Instruction Codes
1. Instruction format in (a) is based on implied addresses.
It can be used to specify operations such as clear a
CPU register, complement a register, or transfer
the contents on register to another register.
2. It has an operation code followed by an immediate
operand. It can be used to initialize a CPU register or
operation such ads add the operand to the present
contents of a register.
3. It has an operation code followed by an address.
Operand must be fetched the memory location
specified by the address parts of the instruction.

Vous aimerez peut-être aussi