Computer System Comparison of Computer Organization & Architecture: 1. Computer Organization and Architecture
Computer System Comparison of Computer Organization & Architecture: 1. Computer Organization and Architecture
● The I/O transfer rate is limited by the speed with which the processor can
test and service a device.
Bus Request : It is used by the DMA controller to request the CPU to relinquish the
control of the buses.
Bus Grant : It is activated by the CPU to Inform the external DMA controller that the
buses are in high impedance state and the requesting DMA can take control of the
buses. Once the DMA has taken the control of the buses it transfers the data. This
transfer can take place in many ways.
Types of DMA transfer using DMA controller:
Burst Transfer :
DMA returns the bus after complete data transfer. A register is used as a byte count,
being decremented for each byte transfer, and upon the byte count reaching zero, the
DMAC will
release the bus. When the DMAC operates in burst mode, the CPU is halted for the
duration of the data
transfer.
Steps involved are:
a. Bus grant request time.
b. Transfer the entire block of data at transfer rate of device because the device is
usually slow than the
speed at which the data can be transferred to CPU.
c. Release the control of the bus back to CPU
So, total time taken to transfer the N bytes
= Bus grant request time + (N) * (memory transfer rate) + Bus release control
time.
Where,
X µsec =data transfer time or preparation time (words/block)
Y µsec =memory cycle time or cycle time or transfer time (words/block)
% CPU idle (Blocked)=(Y/X+Y)*100
% CPU Busy=(X/X+Y)*100
Cyclic Stealing :
An alternative method in which DMA controller transfers one word at a time after
which it must return the control of the buses to the CPU. The CPU delays its
operation only for one memory cycle to allow the direct memory I/O transfer to
“steal” one memory cycle.
Steps Involved are:
d. Buffer the byte into the buffer
e. Inform the CPU that the device has 1 byte to transfer (i.e. bus grant request)
f. Transfer the byte (at system bus speed)
g. Release the control of the bus back to CPU.
Before moving on transfer next byte of data, device performs step 1 again so
that bus isn’t tied up and
the transfer won’t depend upon the transfer rate of device.
So, for 1 byte of transfer of data, time taken by using cycle stealing mode (T).
= time required for bus grant + 1 bus cycle to transfer data + time required to
release the bus, it will be
NxT
In cycle stealing mode we always follow pipelining concept that when one byte is
getting transferred then Device is parallel preparing the next byte. “The fraction of
CPU time to the data transfer time” if asked then cycle stealing mode is used.
Where,
X µsec =data transfer time or preparation time
(words/block)
Y µsec =memory cycle time or cycle time or transfer
time (words/block)
% CPU idle (Blocked) =(Y/X)*100
% CPU busy=(X/Y)*100