Input Output Systems


Question 1
Which of the following is major part of time taken when accessing data on the disk?
A
Settle time
B
Rotational latency
C
Seek time
D
Waiting time
Input Output Systems    
Discuss it


Question 1 Explanation: 
Seek time is time taken by the head to travel to the track of the disk where the data to be accessed is stored.
Question 2
We describe a protocol of input device communication below. a. Each device has a distinct address b. The bus controller scans each device in sequence of increasing address value to determine if the entity wishes to communicate. c. The device ready to communicate leaves it data in IO register. d. The data is picked up and the controller moves to step-a above. Identify the form of communication best describes the IO mode amongst the following: Source: nptel
A
Programmed mode of data transfer
B
DMA
C
Interrupt mode
D
Polling
Input Output Systems    
Discuss it


Question 2 Explanation: 
Question 3
From amongst the following given scenarios determine the right one to justify interrupt mode of data-transfer: Source: nptel
A
Bulk transfer of several kilo-byte
B
Moderately large data transfer but more that 1 KB
C
Short events like mouse action
D
Key board inputs
Input Output Systems    
Discuss it


Question 3 Explanation: 
Both keyboard and mouse controllers typically use interrupt mode.
Question 4
Normally user programs are prevented from handling I/O directly by I/O instructions in them. For CPUs having explicit I/O instructions, such I/O protection is ensured by having the I/O instructions privileged. In a CPU with memory mapped I/O, there is no explicit I/O instruction. Which one of the following is true for a CPU with memory mapped I/O? (GATE CS 2005)
A
I/O protection is ensured by operating system routine(s)
B
I/O protection is ensured by a hardware trap
C
I/O protection is ensured during system configuration
D
I/O protection is not possible
Input Output Systems    
Discuss it


Question 4 Explanation: 
Question 5
Put the following disk scheduling policies results in minimum amount of head movement.
A
FCFS
B
Circular SCAN
C
Elevator
Input Output Systems    
Discuss it


Question 5 Explanation: 
Circular scanning works just like the elevator to some extent. It begins its scan toward the nearest end and works its way all the way to the end of the system. Once it hits the bottom or top it jumps to the other end and moves in the same direction. Circular SCAN has more head movement than SCAN (elevator) because Circular SCAN has circular jump and it does count as a head movement. SCAN (elevator) is the best choice here.
Question 6
Consider a hard disk with 16 recording surfaces (0-15) having 16384 cylinders (0-16383) and each cylinder contains 64 sectors (0-63). Data storage capacity in each sector is 512 bytes. Data are organized cylinder-wise and the addressing format is <cylinder no., surface no., sector no.> . A file of size 42797 KB is stored in the disk and the starting disk location of the file is <1200, 9, 40>. What is the cylinder number of the last sector of the file, if it is stored in a contiguous manner?
A
1281
B
1282
C
1283
D
1284
Input Output Systems    GATE CS 2013    
Discuss it


Question 6 Explanation: 
42797KB will take 85512 sectors (42797*1024 bytes / 512 bytes)

Since there are 64 sectors per surface, 85512/64 = 1337.406 
sectors are required, so we take 1338 sectors these sectors are
distributed among 16 surfaces, so 1338/16 = 83.58 cylinders will be 
required.

So the final ans will be 84+1200 = 1284.

one more fact to be noted is that the file occupies 83.58 cylinders,
but the 0.58 cannot be accommodated in the first one (the file storage
starts from <1200,9,40>). Hence, the file will be extended to 194
(85594-85400) more bytes of cylinder 1284. 
Question 7
A file system with 300 GByte disk uses a file descriptor with 8 direct block addresses, 1 indirect block address and 1 doubly indirect block address. The size of each disk block is 128 Bytes and the size of each disk block address is 8 Bytes. The maximum possible file size in this file system is
A
3 Kbytes
B
35 Kbytes
C
280 Bytes
D
Dependent on the size of the disk
GATE CS 2012    Input Output Systems    
Discuss it


Question 8
A computer handles several interrupt sources of which the following are relevant for this question.

. Interrupt from CPU temperature sensor (raises interrupt if 
  CPU temperature is too high)
. Interrupt from Mouse(raises interrupt if the mouse is moved 
  or a button is pressed)
. Interrupt from Keyboard(raises interrupt when a key is 
  pressed or released)
. Interrupt from Hard Disk(raises interrupt when a disk 
  read is completed)
Which one of these will be handled at the HIGHEST priority?
A
Interrupt from Hard Disk
B
Interrupt from Mouse
C
Interrupt from Keyboard
D
Interrupt from CPU temperature sensor
Input Output Systems    GATE CS 2011    
Discuss it


Question 8 Explanation: 
Higher priority interrupt levels are assigned to requests which, if delayed or interrupted, could have serious consequences. Devices with high speed transfer such as magnetic disks are given high priority, and slow devices such as keyboard receive low priority (Source: Computer System Architecture by Morris Mano) Interrupt from CPU temperature sensor would have serious consequences if ignored.
Question 9
An application loads 100 libraries at start-up. Loading each library requires exactly one disk access. The seek time of the disk to a random location is given as 10 ms. Rotational speed of disk is 6000 rpm. If all 100 libraries are loaded from random locations on the disk, how long does it take to load all libraries? (The time to transfer data from the disk block once the head has been positioned at the start of the block may be neglected)
A
0.50 s
B
1.50 s
C
1.25 s
D
1.00 s
Input Output Systems    GATE CS 2011    
Discuss it


Question 9 Explanation: 
Question 10
A CPU generally handles an interrupt by executing an interrupt service routine
A
As soon as an interrupt is raised
B
By checking the interrupt register at the end of fetch cycle.
C
By checking the interrupt register after finishing the execution of the current instruction.
D
By checking the interrupt register at fixed time intervals.
Input Output Systems    GATE-CS-2009    
Discuss it


Question 10 Explanation: 
Hardware detects interrupt immediately, but CPU acts only after its current instruction. This is followed to ensure integrity of instructions.
There are 44 questions to complete.

Company Wise Coding Practice    Topic Wise Coding Practice