3. BITS Pilani, Pilani Campus
I/O Techniques
โข Polling:
โ CPU check on the status of an I/O device by reading
a memory address which is associated with an I/O
device
โ Pseudo-asynchronous
โข Processor inspects (multiple) devices in rotation
โ Cons
โข Processor may still be forced to do useless work or wait or
both
โ Pros
โข CPU can determines how often it needs to poll
3
4. BITS Pilani, Pilani Campus
I/O Techniques
โข Interrupts:
โ Processor initiates I/O by requesting an operation
with the device.
โ May disconnect if response canโt be immediate,
which is usually the case
โ When device is ready with a response it interrupts
the processor.
โข Processor finishes I/O with the device.
โ Asynchronous but
โข Data transfer between I/O device and memory still
requires processor to execute instructions.
4
6. BITS Pilani, Pilani Campus
I/O Techniques
โข Direct Memory Access
โ Processor initiates I/O
โ DMA controller acts as an intermediary:
โข interacts with the device,
โข transfers data to/from memory as appropriate, and
โข interrupts processor to signal completion.
โ From the processorโs perspective DMA controller is
yet another device
โข But one that works at semiconductor speeds
6
7. BITS Pilani, Pilani Campus
I/O Techniques
โข I/O Processor
โ More sophisticated version of DMA controller
with the ability to execute code: execute I/O
routines, interact with the O/S etc
7