Eroxl's Notes
Programmed Input-Output

Programmed I/O (PIO) is a data transfer method where the CPU directly transfers data one byte at a time between itself and an I/O controller. The CPU uses standard load and store instructions to I/O-mapped memory addresses to perform these transfers. PIO is always initiated by the CPU, not by the I/O controller.

Limitations

PIO has several significant limitations:

  • CPU overhead: The CPU must actively transfer each byte, wasting cycles that could be used for computation
  • Speed mismatch: I/O devices and controllers are much slower than the CPU, forcing the CPU to wait frequently
  • Unidirectional initiation: Only the CPU can initiate transfers; controllers cannot initiate communication even when they have data available

These limitations make PIO inefficient for transferring large amounts of data or handling asynchronous device events, leading to the development of DMA and interrupts.