0% found this document useful (0 votes)
18 views

Unit 3

Uploaded by

kushal
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views

Unit 3

Uploaded by

kushal
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

CAO - UNIT 3

Syllabus:

Control unit Design: Hardwired and microprogrammed design


approaches.

1. What is a Control Unit in Computer Architecture?

The CPU control unit is a component of the computer’s CPU (central processing unit)
that directs the processor’s operation. John von Neumann included it in his Von
Neumann Architecture. The control unit’s job is to instruct the computer’s
arithmetic/logic unit, memory, and input and output devices on how to respond to the
instructions supplied to the processor.

The control unit fetches internal program instructions from the main memory to the
processor instruction register, and it generates a control signal based on the contents of
this register to supervise the execution of these instructions.

2. How Does a CPU Control Unit work?

A control unit receives data from the user and translates it into control signals that are
subsequently delivered to the central processor. The processor of the computer then
instructs the associated hardware on what operations to do. Because CPU architecture
differs from manufacturer to manufacturer, the functions performed by a control unit in
a computer are dependent on the CPU type. The following are some examples of
devices requiring a control unit:

 CPUs or Central Processing Units


 GPUs or Graphics Processing Units
3. Why Control Unit Design is important in Computer Architecture?

OR

Explain the Function of Control Unit.

 It coordinates the flow of data out of, into, and between the various subunits of
a processor.
 It understands commands and instructions.
 It regulates the flow of data within the processor.
 It accepts external commands or instructions, which it turns into a series of
control signals.
 It is in charge of a CPU’s multiple execution units (such as ALUs, data buffers,
and registers).
 It also performs a variety of activities, including fetching, decoding, handling
execution, and storing results.

4. Explain Hard Wired Unit Design in detail.

A hard-wired control is a mechanism of producing control signals using Finite State


Machines (FSM) appropriately. It is designed as a sequential logic circuit. The final
circuit is constructed by physically connecting the components such as gates, flip flops,
and drums. Hence, it is named a hard-wired controller.

The figure shows a 2-bit sequence counter, which is used to develop control signals.
The output obtained from these signals is decoded to generate the required signals in
sequential order.
The hard-wired control consists of a combinational circuit that outputs desired controls
for decoding and encoding functions. The instruction that is loaded in the IR is decoded
by the instruction decoder. If the IR is an 8-bit register, then the instruction decoder
generates 28 (256) lines.

Inputs to the encoder are given from the instruction step decoder, external inputs, and
condition codes. All these inputs are used and individual control signals are generated.
The end signal is generated after all the instructions get executed. Furthermore, it results
in the resetting of the control step counter, making it ready to generate the control step
for the next instruction.

5. Explain Advantages (Benefits) of Hard-wired control unit design.

1) Because of the use of combinational circuits to generate signals, Hard-wired


Control Unit is fast.
2) It depends on number of gates, how much delay can occur in generation of control
signals.
3) It can be optimized to produce the fast mode of operation.
4) Faster than micro- programmed control unit.
5) It does not require control memory.

6. Explain Disadvantages (Limitations) of Hard-wired control unit design.


1) The complexity of the design increases as we require more control signals to be
generated (need of more encoders & decoders)
2) Modifications in the control signals are very difficult because it requires
rearranging of wires in the hardware circuit.
3) Adding a new feature is difficult & complex.
4) Difficult to test & correct mistakes in the original design.
5) It is Expensive.

7. Explain Microprogrammed Control Unit Design in detail.

A control unit whose binary control values are saved as words in memory is called a
microprogrammed control unit.

A controller results in the instructions to be implemented by constructing a definite


collection of signals at each system clock beat. Each of these output signals generates
one micro-operation including register transfer. Thus, the sets of control signals are
generated definite micro-operations that can be saved in the memory.

Each bit that forms the microinstruction is linked to one control signal. When the bit is
set, the control signal is active. When it is cleared the control signal turns inactive.
These microinstructions in a sequence can be saved in the internal ’control’ memory.
The control unit of a microprogram-controlled computer is a computer inside a
computer.

The following image shows the block diagram of a Microprogrammed Control


organization.

There are the following steps followed by the microprogrammed control are −
 It can execute any instruction. The CPU should divide it down into a set of
sequential operations. This set of operations are called microinstruction. The
sequential micro-operations need the control signals to execute.
 Control signals saved in the ROM are created to execute the instructions on the
data direction. These control signals can control the micro-operations concerned
with a microinstruction that is to be performed at any time step.
 The address of the microinstruction is executed next is generated.
 The previous 2 steps are copied until all the microinstructions associated with
the instruction in the set are executed.

8. Explain Advantages and Disadvantages of Microprogrammed control design.

There are the following advantages of microprogrammed control are as follows −

 It can more systematic design of the control unit.


 It is simpler to debug and change.
 It can retain the underlying structure of the control function.
 It can make the design of the control unit much simpler. Hence, it is inexpensive
and less error-prone.
 It can orderly and systematic design process.
 It is used to control functions implemented in software and not hardware.
 It is more flexible.
 It is used to complex function is carried out easily.

There are the following disadvantages of microprogrammed control are as follows −

 Adaptability is obtained at more cost.


 It is slower than a hard-wired control unit.

9. Explain the Applications of Microprogrammed Control Unit.

Microprogramming has many advantages like flexibility, simplicity, cost-


effectiveness etc.
Therefore, it has a major contribution in the following applications –
1. Development of control units –
Modern processors have very large and complex instruction sets.
Microprogramming is used for making control units of such processors, because
it is far less complex and can be easily modified.
2. High level language support –
Modern high level languages have more advanced and complex data types.
Microprogramming can provide support for such data types directly from the
processor level. Therefore, the language becomes easy to compile and also faster
to execute.
3. User tailoring of the control unit –
As the control Unit is developed using software, it can be easily reprogrammed.
This can be used for custom-made modifications of the Control Unit. For this
purpose, the control memory must be writable like RAM or flash ROMs.
4. Emulation –
Emulation is when one processor (say A) is made to emulate or behave like
another processor (say B). To do this, A must be able to execute the instructions
of B. If we re-program the control memory of A, same as that of B, then A will be
able to emulate the behavior of B, for every instruction. This is possible only in
microprogrammed control units.
Used generally when a main processor has to emulate the behavior of a math co-
processor.
5. Improving the operating system –
Microprogramming can be used to implement complex and secure functions of
the OS. This not only makes the OS more powerful and efficient, but more
importantly secure, as it provides the OS a higher degree of protection from
malicious virus attacks.
6. Micro-Diagnostics or error debugging –
As Microprogrammed Control Units are software based, debugging an error is far
more easy as compared to doing the same for a complex hardwired control unit.
This allows monitoring, detection and repairs of any kind of system errors in the
control unit. It can also use as a runtime substitute, if the corresponding hardwired
component fails.
7. Development of special purpose processors –
All processors are not general purpose. Many applications require special purpose
processors like DSP(Digital Signal Processors) for
communication, GPU (Graphic Processor Unit) for image processing.
They have complex instruction sets and also need to be constantly upgraded.
Microprogrammed control unit is the best choice for them

10. Difference between Hardwired and Microprogrammed Control Unit

ATTRIBUTES HARDWIRED MICROPROGRAMMED


CONTROL UNIT CONTROL UNIT

1. Speed Speed is fast Speed is slow

2. Cost of
More costlier. Cheaper.
Implementation

Not flexible to
accommodate new More flexible to accommodate
3. Flexibility system specification or new system specification or new
new instruction redesign instruction sets.
is required.
ATTRIBUTES HARDWIRED MICROPROGRAMMED
CONTROL UNIT CONTROL UNIT

4. Ability to
Difficult to handle Easier to handle complex
Handle Complex
complex instruction sets. instruction sets.
Instructions

Complex decoding and Easier decoding and sequencing


5. Decoding
sequencing logic. logic.

6. Applications RISC Microprocessor CISC Microprocessor

7. Instruction set
Small Large
of Size

8. Control
Absent Present
Memory

9. Chip Area
Less More
Required

Occurrence of error is
10. Occurrence Occurrence of error is less
more

You might also like