Table of contents
1.
Introduction 
2.
Instruction Pipeline
3.
FAQs
4.
Key takeaways-
Last Updated: Mar 27, 2024

Instruction Pipeline

Author Riya
1 upvote
Career growth poll
Do you think IIT Guwahati certified course can help you in your career?

Introduction 

In computer Organisation and Architecture (COA), we study a computer system's internal working and structure and how the various components are organized for their efficient use. 

Pipelining is one of COA techniques used for decomposing a task into smaller subtasks in a pipeline manner for improving the system's performance. In this way, subtasks are arranged in sequential order in a pipeline, where the output of one subtask is used as input for the next subtask. The main advantage of pipelining is the simultaneous execution of various subtasks, which improves the system's throughput.

Also Read - Shift Registers in Digital Electronics

Let's understand the advantage of a pipeline through a simple example:

Suppose the task is to take two integers as input and print their sum as output.

The system will first take the two integers as input, compute their sum, and then print it. Here, another set of two integers will wait until the sum of the previous set of integers is printed. Also, when the system is computing the sum, the parts of the system taking input or printing output are left unused. In this way, the resources are not utilized efficiently.

But if will use a pipeline, we can divide this task into the following subtasks:

  1. Take input
  2. Compute sum
  3. Print the sum

And, if these three subtasks are executed parallelly, we will get faster execution of the task. While the system is computing the sum of two integers, it will parallelly take the next set of integers as input, and this way, the number of tasks in a given interval of time will increase.

There are mainly two types of pipelines in COA. They are:

  1. Arithmetic Pipeline
  2. Instruction Pipeline

This article will discuss the 'Instruction Pipeline' in detail.

Recommended Topic, Microinstruction in Computer Architecture

Instruction Pipeline

Instruction pipelines are used to divide the task of executing a stream of instructions into subtasks to be executed in different pipeline segments to improve the throughput of the computer system. For example, if we have a stream of instructions, then one segment of the pipeline can read the instructions while another segment can decode the previous instruction. In this way, more than one instruction will be handled simultaneously by the computer system that will improve its throughput. The instruction pipeline will be more efficient if the instructions are divided into equal duration segments.

A typical example of instruction pipeline used by computer systems consists of the following segments:

  1. Segment 1: This segment will fetch the instruction from the memory
  2. Segment 2: This segment will decode the instruction and find out the effective address
  3. Segment 3: This segment will fetch the operands from the memory
  4. Segment 4: This segment will execute the instruction

 

The diagram below shows the instruction pipeline which we have discussed here:

FAQs

  1. What do we study in Computer Organisation and Architecture (COA) ?
    In computer Organisation and Architecture (COA), we study a computer system's internal working and structure and how the various components are organized for their efficient use. 
     
  2. What is pipelining?
    Pipelining is one of the techniques in COA used for decomposing a task into smaller subtasks performed in a sequential manner to improve the system's performance.

Key takeaways-

In this article, we first discussed the pipelining technique used in Computer Organisation and Architecture and then discussed ‘Instruction Pipeline’ in detail.

If you think that this blog helped you share it with your friends!. To be more confident in data structures and algorithms, try out our DS and Algo Course.

Also read, Data Warehouse Architecture

Until then, All the best for your future endeavours, and Keep Coding.

Live masterclass