11.07.2015 Views

Encyclopedia of Computer Science and Technology

Encyclopedia of Computer Science and Technology

Encyclopedia of Computer Science and Technology

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Input/Output 243monitored the flow <strong>of</strong> data until it was complete. While thisarrangement simplified computer architecture <strong>and</strong> reducedthe cost <strong>of</strong> memory units or peripheral devices (at a timeSteps in processing an interrupt request (IRQ) in a PC. (1) Thedevice requesting attention signals the Interrupt Controller, whichin turn sends a special signal to the CPU. (2) The CPU savesits state (including internal data <strong>and</strong> the address <strong>of</strong> the currentinstruction) to a stack. (3) The CPU gets the interrupt number <strong>and</strong>other information from the Interrupt Controller, then looks up aset <strong>of</strong> instructions for processing that particular interrupt. (4) TheCPU executes the interrupt processing code, which generally linksto BIOS code for h<strong>and</strong>ling a device such as the keyboard. (5) TheCPU reloads its state information from the stack <strong>and</strong> resumes theinterrupted processing.when computer hardware was h<strong>and</strong>-built <strong>and</strong> relativelycostly), it also meant that the CPU could perform no otherprocessing until I/O was complete.In most modern computers, responsibility for I/O haslargely been removed from the CPU, freeing it to concentrateon computation. There are several ways to implementsuch architecture. One method that has been used onmicrocomputers since their earliest day is interrupt-drivenI/O. This means that the CPU has separate circuits onwhich a device requesting I/O service can “post” a request.The CPU periodically checks the circuits for an interruptrequest (IRQ). If one is found, it can send a query to eachdevice on a list until the correct one is found (the latteris called polling). Alternatively, the overhead involved inpolling can be eliminated by having the IRQ include eithera device identification number or a memory address thatcontains an interrupt service routine (this is called vectoredinterrupts). While interrupts alone do not free the CPU <strong>of</strong>the need to manage the I/O, they do remove the overhead <strong>of</strong>having to frequently check all devices for I/O.The actual I/O process can also be moved out <strong>of</strong> theCPU through the use <strong>of</strong> direct memory access (DMA). Herea separate control device takes over control <strong>of</strong> the systemfrom the CPU when I/O is requested. It then transfers datadirectly between a device (such as a hard disk drive) <strong>and</strong>a buffer in main memory. Although the CPU is idle duringthis process, the transfer is accomplished much morequickly because the full capacity <strong>of</strong> the bus can be used tomove data rather than having to be shared with the flow <strong>of</strong>program instructions in the CPU.A more sophisticated I/O control device is called a channel.A channel controller can operate completely independently<strong>of</strong> the CPU without requiring that the CPU becomeidle during a transfer. Channels can also act as a sort <strong>of</strong> specializedCPU or coprocessor, running program instructionsto monitor the data transfer. There are also channels capable<strong>of</strong> monitoring <strong>and</strong> controlling several devices simultaneously(this is called multiplexing). The use <strong>of</strong> channels inmainframes such as the IBM 360 <strong>and</strong> its descendants is onereason why mainframes still perform a workhorse role inhigh-volume data processing.In microcomputers the trend has also been toward<strong>of</strong>floading I/O from the CPU <strong>and</strong> the main bus to separatecontrollers or channels. For example, the AGP (acceleratedgraphics port) found on most modern PCs acts as achannel between main memory <strong>and</strong> the graphics controllers(see graphics card). This means that as a programgenerates graphics data it can be automatically transferredfrom memory to the graphics controllers without any loadon the CPU, <strong>and</strong> over a bus that is faster than the mainsystem bus.Further ReadingBuchanan, William. Applied PC Interfacing, Graphics <strong>and</strong> Interrupts.Reading, Mass.: Addison-Wesley, 1999.Karbo, Michael B. “About the PC I/O System.” Available online.URL: http://www.karbosguide.com/hardware/module5a1a.htm. Accessed August 8, 2007.White, Ron, <strong>and</strong> Timothy Downs. How <strong>Computer</strong>s Work. 8th ed.Indianapolis: Que, 2005.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!