Programmed IO and Interrupt initiated IO
Why are they used?
CPU merely executes instruction and accepts
data temporally from I/O device.
Ultimate source and destination is memory.
Data transfer is handled in a variety modes.
What are the different modes?
Data transfer can be handled in one of three
modes-
Programmed I/O
Interrupt Initiated I/O
Direct Memory Access (DMA)
Programmed I/O
Each data transfer is initiated by an I/O
instruction written in a computer program.
Transferring data under program control
requires constant monitoring of the
peripheral by CPU.
In this mode CPU stays in a program loop
until I/O unit is ready for data transfer.
This time-consuming process keeps the
processor needlessly busy.
Interrupt Initiated I/O
Instead of continuous monitoring of CPU,
Interface will be informed by issue an interrupt
request signal.
Meanwhile, CPU proceeds to executes another
program and the interface keeps monitoring
the device.
When device is ready for data transfer it
generates interrupt signal.
Here CPU stops the tasks it is performing and
process the data transfer and resume the
original program.
Difference between programmed I/O and
Interrupt Initiated I/O.
Interrupt initiated I/O Programmed I/O
Data transfer is initiated by the The I/O transfer is initiated by
means of instructions stored in the interrupt command issued
the computer program. to the CPU.
CPU continuously monitor the Interface monitor the devices.
peripheral device.
CPU becomes idle. CPU utilization gets better.
It is quite easy to program and It can be tricky and
understand. complicated to understand if
one uses low level language.
THANK YOU!!