The Wayback Machine - https://web.archive.org/web/20240907084329/https://www.geeksforgeeks.org/computer-organization-hardwired-vs-micro-programmed-control-unit/
Open In App

Computer Organization | Hardwired v/s Micro-programmed Control Unit

Last Updated : 07 Apr, 2023
Comments
Improve
Suggest changes
Like Article
Like
Save
Share
Report
News Follow

Introduction :

In computer architecture, the control unit is responsible for directing the flow of data and instructions within the CPU. There are two main approaches to implementing a control unit: hardwired and micro-programmed.

A hardwired control unit is a control unit that uses a fixed set of logic gates and circuits to execute instructions. The control signals for each instruction are hardwired into the control unit, so the control unit has a dedicated circuit for each possible instruction. Hardwired control units are simple and fast, but they can be inflexible and difficult to modify.

On the other hand, a micro-programmed control unit is a control unit that uses a microcode to execute instructions. The microcode is a set of instructions that can be modified or updated, allowing for greater flexibility and ease of modification. The control signals for each instruction are generated by a microprogram that is stored in memory, rather than being hardwired into the control unit.

Micro-programmed control units are slower than hardwired control units because they require an extra step of decoding the microcode to generate control signals, but they are more flexible and easier to modify. They are commonly used in modern CPUs because they allow for easier implementation of complex instruction sets and better support for instruction set extensions.

To execute an instruction, the control unit of the CPU must generate the required control signal in the proper sequence. There are two approaches used for generating the control signals in proper sequence as Hardwired Control unit and the Micro-programmed control unit. 

Hardwired Control Unit: The control hardware can be viewed as a state machine that changes from one state to another in every clock cycle, depending on the contents of the instruction register, the condition codes, and the external inputs. The outputs of the state machine are the control signals. The sequence of the operation carried out by this machine is determined by the wiring of the logic elements and hence named “hardwired”. 

  • Fixed logic circuits that correspond directly to the Boolean expressions are used to generate the control signals.
  • Hardwired control is faster than micro-programmed control.
  • A controller that uses this approach can operate at high speed.
  • RISC architecture is based on the hardwired control unit

1

Micro-programmed Control Unit –  

  • The control signals associated with operations are stored in special memory units inaccessible by the programmer as Control Words.
  • Control signals are generated by a program that is similar to machine language programs.
  • The micro-programmed control unit is slower in speed because of the time it takes to fetch microinstructions from the control memory.

Some Important Terms

  1. Control Word: A control word is a word whose individual bits represent various control signals.
  2. Micro-routine: A sequence of control words corresponding to the control sequence of a machine instruction constitutes the micro-routine for that instruction.
  3. Micro-instruction: Individual control words in this micro-routine are referred to as microinstructions.
  4. Micro-program: A sequence of micro-instructions is called a micro-program, which is stored in a ROM or RAM called a Control Memory (CM).
  5. Control Store: the micro-routines for all instructions in the instruction set of a computer are stored in a special memory called the Control Store.

2

The differences between hardwired and micro-programmed control units:

  Hardwired Control Unit  Micro-programmed Control Unit
 
Implementation  Fixed set of logic gates and circuits  Microcode stored in memory
 
Flexibility  Less flexible, difficult to modify  More flexible, easier to modify
 
Instruction Set  Supports limited instruction sets  Supports complex instruction sets
 
Complexity of Design  Simple design, easy to implement  Complex design, more difficult to implement
 
Speed  Fast operation  Slower operation due to microcode decoding
 
Debugging and Testing  Difficult to debug and test  Easier to debug and test
 
Size and Cost  Smaller size, lower cost  Larger size, higher cost
 
Maintenance and Upgradability  Difficult to upgrade and maintain  Easier to upgrade and maintain
 

Types of Micro-programmed Control Unit – Based on the type of Control Word stored in the Control Memory (CM), it is classified into two types : 

1. Horizontal Micro-programmed Control Unit : 
The control signals are represented in the decoded binary format that is 1 bit/CS. Example: If 53 Control signals are present in the processor then 53 bits are required. More than 1 control signal can be enabled at a time. 

  • It supports longer control words.
  • It is used in parallel processing applications.
  • It allows a higher degree of parallelism. If degree is n, n CS is enabled at a time.
  • It requires no additional hardware(decoders). It means it is faster than Vertical Microprogrammed.
  • It is more flexible than vertical microprogrammed

2. Vertical Micro-programmed Control Unit : 
The control signals are represented in the encoded binary format. For N control signals- Log2(N) bits are required.  

  • It supports shorter control words.
  • It supports easy implementation of new control signals therefore it is more flexible.
  • It allows a low degree of parallelism i.e., the degree of parallelism is either 0 or 1.
  • Requires additional hardware (decoders) to generate control signals, it implies it is slower than horizontal microprogrammed.
  • It is less flexible than horizontal but more flexible than that of a hardwired control unit.

Note: Types of Control Unit in descending order of speed :

Hardwired control unit > Horizontal microprogrammed CU > Vertical microprogrammed CU 

GATE CS Corner Questions 
Practicing the following questions will help you test your knowledge. All questions have been asked in GATE in previous years or in GATE Mock Tests. It is highly recommended that you practice them.  

  1. GATE CS 2004, Question 66
  2. GATE CS 2002, Question 32

 

 


Previous Article
Next Article

Similar Reads

Difference between Hardwired and Micro-programmed Control Unit | Set 2
Prerequisite - Hardwired v/s Micro-programmed Control Unit To execute an instruction, there are two types of control units Hardwired Control unit and Micro-programmed control unit. Hardwired control units are generally faster than microprogrammed designs. In hardwired control, we saw how all the control signals required inside the CPU can be genera
2 min read
Difference between Horizontal and Vertical micro-programmed Control Unit
Prerequisite - Hardwired v/s Micro-programmed Control Unit The control unit (CU) is the engine that runs the entire functions of a computer with the help of control signals in the proper sequence. In the micro-programmed control unit approach, the control signals that are associated with the operations are stored in special memory units. It is conv
3 min read
Difference between Hardwired and Microprogrammed Control Unit
Prerequisite - Hardwired and Micro-programmed Control Unit Control unit generates control signal using one of the two organizations: Hardwired Control Unit, Microprogrammed Control Unit. Hardwired Control Unit: It is implemented as logical circuit (gates, flip-flops, decoders etc.) in the hardware. This organization is very complicated if we have a
2 min read
Advantages & Disadvantages of Hardwired Control Unit
In this article, we will discuss the overview of the control unit and their types. And our main focus will be on the Advantages & Disadvantages of the Hardwired Control Unit. Let's discuss it one by one as follows. Control Unit :The unit which directs the operation of the processor & is a part of the CPU is known as Control Unit. It generat
3 min read
Designing methods of hardwired control unit
Prerequisites : Hardwired control unit Here the control signals are generated using hardware. There are three types of Hardwired Control Units.1. State table method : Here the behavior of control unit is represented in the form of a table, which is known as the state table.Here, each row represents the T-states and the columns represent the instruc
6 min read
Computer Organization | Micro-Operation
In computer central processing units, micro-operations (also known as micro-ops) are the functional or atomic, operations of a processor. These are low level instructions used in some designs to implement complex machine instructions. They generally perform operations on data stored in one or more registers. They transfer data between registers or
3 min read
Difference between Programmed and Interrupt Initiated I/O
Prerequisite - I/O Interface (Interrupt and DMA Mode) Data transfer between the CPU and I/O devices can be done in variety of modes. These are three possible modes: Programmed I/OInterrupt initiated I/ODirect Memory Access (DMA) In this article we shall discuss the first two modes only. 1. Programmed I/O : In this mode the data transfer is initiate
3 min read
Control Logic Gates in Computer Organization
Control Logic Gates is the hardware component of a basic computer. It comprises some inputs and outputs. The diagram given below is related to the hardwired control organization. The diagram below consists of the instruction register which has three parts: the I bit (15), the operation code (12, 13, 14), and bits 0 through 11. The symbols as D0 to
2 min read
Shift Micro-Operations in Computer Architecture
Shift micro-operations are those micro-operations that are used for the serial transfer of information. These are also used in conjunction with arithmetic micro-operation, logic micro-operation, and other data-processing operations. There are three types of shift micro-operations: 1. Logical ShiftIt transfers the 0 zero through the serial input. We
7 min read
Computer Organization | Basic Computer Instructions
Introduction : Computer organization refers to the way in which the components of a computer system are organized and interconnected to perform specific tasks. One of the most fundamental aspects of computer organization is the set of basic computer instructions that the system can execute. Basic computer instructions are the elementary operations
6 min read
Differences between Computer Architecture and Computer Organization
Computer Architecture is a functional description of requirements and design implementation for the various parts of a computer. It deals with the functional behavior of computer systems. It comes before the computer organization while designing a computer. Computer architecture and computer organization are related but distinct concepts in the fie
3 min read
Performance of Computer in Computer Organization
In computer organization, performance refers to the speed and efficiency at which a computer system can execute tasks and process data. A high-performing computer system is one that can perform tasks quickly and efficiently while minimizing the amount of time and resources required to complete these tasks. There are several factors that can impact
5 min read
Introduction of Control Unit and its Design
A Central Processing Unit is the most important component of a computer system. A control unit is a part of the CPU. A control unit controls the operations of all parts of the computer but it does not carry out any data processing operations. What is a Control Unit?The Control Unit is the part of the computer's central processing unit (CPU), which
10 min read
Applications of Microprogrammed Control Unit
Prerequisite : Introduction of Control Unit and its Design Microprogrammed Control Unit :Microprogrammed Control Unit produces control signals by using micro-instructions. Micro program : A program is a set of instructions. An instruction requires a set of micro-operations.Micro-operations are performed using control signals.Here, these control sig
4 min read
Arithmetic Micro-operations in Registers
We can perform arithmetic operations on the numeric data which is stored inside the registers. Example : R3 <- R1 + R2 The value in register R1 is added to the value in the register R2 and then the sum is transferred into register R3. Similarly, other arithmetic micro-operations are performed on the registers. Addition - In addition micro-operat
3 min read
Nano programming in Micro Instruction Format
In this article, we will discuss Nano programming in micro-instruction format in detail and also will understand with the help of example and also will discuss the need for Nano programming. Let's discuss it one by one. Pre-requisites -Horizontal and vertical microinstruction Micro instruction format :The control field of the micro-instruction deci
4 min read
Micro Instruction Sequencing
Need for designing the micro-instruction sequencing technique : The first purpose is to minimize the size of control memory because control memory is present inside the processor.The second purpose is to execute the micro-instructions as fast as possible. Which means the address of the next micro-instruction can be calculated as fast as possible. T
4 min read
Implementation of Micro Instructions Sequencer
The address is used by a microprogram sequencer to decide which microinstruction has to be performed next. Microprogram sequencing is the name of the total procedure. The addresses needed to step through a control store's microprogram are created by a sequencer, also known as a microsequencer. The control unit's main job is to communicate with the
4 min read
Computer Organization | Amdahl's law and its proof
It is named after computer scientist Gene Amdahl( a computer architect from IBM and Amdahl corporation) and was presented at the AFIPS Spring Joint Computer Conference in 1967. It is also known as Amdahl's argument. It is a formula that gives the theoretical speedup in latency of the execution of a task at a fixed workload that can be expected of a
6 min read
Computer Organization | Different Instruction Cycles
Introduction : Prerequisite - Execution, Stages and Throughput Registers Involved In Each Instruction Cycle: Memory address registers(MAR) : It is connected to the address lines of the system bus. It specifies the address in memory for a read or write operation.Memory Buffer Register(MBR) : It is connected to the data lines of the system bus. It co
11 min read
Computer Organization | Booth's Algorithm
Booth algorithm gives a procedure for multiplying binary integers in signed 2’s complement representation in efficient way, i.e., less number of additions/subtractions required. It operates on the fact that strings of 0’s in the multiplier require no addition but just shifting and a string of 1’s in the multiplier from bit weight 2^k to weight 2^m
7 min read
Computer Organization | Problem Solving on Instruction Format
Prerequisite - Basic Computer Instructions, Instruction Formats Problem statement: Consider a computer architecture where instructions are 16 bits long. The first 6 bits of the instruction are reserved for the opcode, and the remaining 10 bits are used for the operands. There are three addressing modes: immediate, direct, and register. For immediat
7 min read
Computer Organization | Asynchronous input output synchronization
Introduction : Asynchronous input/output (I/O) synchronization is a technique used in computer organization to manage the transfer of data between the central processing unit (CPU) and external devices. In asynchronous I/O synchronization, data transfer occurs at an unpredictable rate, with no fixed timing or synchronization between the CPU and ext
7 min read
Computer Organization | Locality and Cache friendly code
Caches are the faster memories that are built to deal with the Processor-Memory gap in data read operation, i.e. the time difference in a data read operation in a CPU register and that in the main memory. Data read operation in registers is generally 100 times faster than in the main memory and it keeps on increasing substantially, as we go down in
7 min read
MPU Communication in Computer Organization
MPU communicates with the outside world with the help of some external devices which are known as Input/Output devices. The MPU accepts the binary data from input devices such as keyboard and analog/digital converters and sends data to output devices such as printers and LEDs. For performing this task, MPU first need to identify the input/output de
4 min read
Purpose of an Interrupt in Computer Organization
Interrupt is the mechanism by which modules like I/O or memory may interrupt the normal processing by CPU. It may be either clicking a mouse, dragging a cursor, printing a document etc the case where interrupt is getting generated. Why we require Interrupt? External devices are comparatively slower than CPU. So if there is no interrupt CPU would wa
2 min read
Peripherals Devices in Computer Organization
Generally peripheral devices, however, are not essential for the computer to perform its basic tasks, they can be thought of as an enhancement to the user's experience. A peripheral device is a device that is connected to a computer system but is not part of the core computer system architecture. Generally, more people use the term peripheral more
4 min read
Data Manipulation Instructions in Computer Organization
Data Manipulation Instructions Data manipulation instructions perform operations on data and provide computational capabilities for the computer. The data manipulation instructions in a typical computer are usually divided into three basic types as follows. Arithmetic instructionsLogical and bit manipulation instructionsShift instructions Let's dis
3 min read
Stack Frame in Computer Organization
Stack Frame :Stack is one of the segments of application memory that is used to store the local variables, function calls of the function. Whenever there is a function call in our program the memory to the local variables and other function calls or subroutines get stored in the stack frame. Each function gets its own stack frame in the stack segme
3 min read
Memory Stack Organization in Computer Architecture
A stack is a storage device in which the information or item stored last is retrieved first. Basically, a computer system follows a memory stack organization, and here we will look at how it works. A portion of memory is assigned to a stack operation to implement the stack in the CPU. Here the processor register is used as a Stack Pointer (SP). The
4 min read
Practice Tags :