Open In App

Purpose of an Interrupt in Computer Organization

Improve
Improve
Like Article
Like
Save
Share
Report

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 waste a lot of time waiting for external devices to match its speed with that of CPU. This decreases the efficiency of CPU. Hence, interrupt is required to eliminate these limitations. With Interrupt:

  1. Suppose CPU instructs printer to print a certain document.
  2. While printer does its task, CPU engaged in executing other tasks.
  3. When printer is done with its given work, it tells CPU that it has done with its work. (The word ‘tells’ here is interrupt which sends one message that printer has done its work successfully.).

Advantages:

  • It increases the efficiency of CPU.
  • It decreases the waiting time of CPU.
  • Stops the wastage of instruction cycle.
  • Enables multitasking by allowing the CPU to quickly switch between different processes.
  • Simplifies input/output (I/O) operations by allowing devices to communicate directly with the CPU.

Disadvantages:

  • CPU has to do a lot of work to handle interrupts, resume its previous execution of programs (in short, overhead required to handle the interrupt request.).
  • Overhead required to handle the interrupt request can reduce the efficiency of the system.
  • Interrupt storms can occur when there is high levels of interrupt activity.
  • Priority inversion can occur when a low-priority task holds a resource needed by a higher-priority task.

Last Updated : 12 May, 2023
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads