GATE / CS ARCHIVE

GATE CSE 2016 SET 1 / QUESTION 31

GATE CSE 2016 Set 1 Q31

Computer Organization & Architecture · Input/Output, DMA & Interrupts · Full GATE CSE 2016 Set 1 paper

GATE 2016 Set 1, Q31 2 marks · NAT
Report issue

Input/Output, DMA & Interrupts

Question 31, GATE 2016: A DMA controller has a 16-bit data-count register. It must transfer 29154 kilobytes from disk into byte-addressable main memory. What is the minimum number of bus acquisitions needed to transfer the file? Use the paper's binary kilobyte and block-transfer convention.
Tap to enlarge
Answer & solution

Official answer: 456.0 : 456.0

Our answer: 456

Under binary kilobytes and burst transfer, a 16-bit count supports at most 2¹⁶ bytes per programmed transfer (or 65535 under a literal maximum-count convention, which gives the same ceiling here). The file has 29154·1024 bytes. Ceiling(29154/64)=456 bus acquisitions. This assumes a DMA burst retains the bus for its programmed block; cycle stealing would count differently. Decimal kilobytes would yield 445, so the binary-unit convention matters.

The file contains 29853696 bytes. A count register bounds bytes per programmed block in byte-addressable memory, so use a ceiling:455 full 64 KiB blocks carry 29818880 bytes, leaving 34816 bytes for one more block. Rounding down would leave data untransferred. If the usable maximum count is 65535 rather than 65536,455 such blocks still fall short and 456 suffice. The answer concerns block ownership episodes, not one bus acquisition per individual byte.

Original paper, page 13 · Answer key