Programmed input / output
Programmed input / output (also known as programmable input / output , PIO for short ) is a set of rules for controlling the exchange of data between the processor and the peripheral devices , especially ATA devices, of a computer .
The processor can use read and write commands to access the memory area of a device and thus transport data between the device and processor registers. If the actual data exchange between peripheral device and main memory is to take place, which is often the case, the processor must write the data received via PIO to the main memory in a further step.
The executing unit for this data exchange is the CPU , i. That is, the processing power of the processor is used. This is one of the main disadvantages of this data exchange method. By using DMA ( direct memory access ), which regulates the exchange of data without the direct involvement of the CPU, a significant performance improvement can be achieved for larger amounts of data. For smaller amounts of data such as control information, PIO is often the better choice.
PIO for hard drives
For reasons of compatibility, hard disks support PIO modes for transferring data. For reasons of performance, however, DMA transfers are mainly used.
Various modes have been specified especially for access to hard disks, which differ in the speed that can be achieved. There are five ATA PIO modes, which have been specified in different versions and offer the following speeds:
mode | Transfer rate | year |
---|---|---|
PIO 0 | 3.33 MB / s | 1989 |
PIO 1 | 5.22 Mbytes / s | |
PIO 2 | 8.33 Mbytes / s | |
PIO 3 | 11.11 Mbytes / s | 1994 |
PIO 4 | 16.66 Mbytes / s |
PIO mode 5 with transfer rates of up to 22.2 MByte / s was no longer implemented, but replaced by the faster Ultra DMA mode with 33 MByte / s.