Thursday, January 25, 2018

Computer Quiz

1. Page fault frequency in an operating system is reduced when the
(A) processes tend to the I/O-bound
(B) size of pages is reduced
(C) processes tend to be CPU-bound
(D) locality of reference is applicable to the process
(E) All of the above

2. The memory allocation scheme subject to “external” fragmentation is
(A) segmentation 
(B) swapping
(C) pure demand paging 
(D) multiple fixed contiguous partitions
(E) None of these

3. The total time to prepare a disk drive mechanism for a block of data to be read from is its
(A) latency
(B) latency plus transmission time
(C) latency plus seek time
(D) latency plus seek time plus transmission time
(E) None of these

4. Page stealing
(A) is a sign of efficient system
(B) is taking page frames other working sets
(C) should be the tuning goal
(D) is taking larger disk spaces for pages paged out
(E) All of the above

5. Relocatable programs
(A) cannot be used with fixed partitions
(B) can be loaded almost anywhere in memory
(C) do not need a linker
(D) can be loaded only at one specific location
(E) only (A) and (D)

6. Resolution of externally defined symbols is performed by
(A) Linker 
(B) Loader
(C) Compiler 
(D) Editor
(E) None of these

7. Relocation bits used by relocating loader are specified by
(A) Relocating loader itself 
(B) Linker
(C) Macro processor 
(D) Assembler or Translator
(E) Both (B) and (C)

8. Virtual memory is
(A) simple to implement
(B) used in all major commercial operating systems
(C) less efficient in utilization of memory
(D) useful when fast I/O devices are not available
(E) All of the above

9. Before proceeding with its execution, each process must acquire all the resources it needs is called
(A) hold and wait 
(B) No pre-emption
(C) circular wait 
(D) starvation
(E) latency

10. SSTF stands for
(A) shortest-seek-time-first 
(B) small-small-time-first
(C) simple-seek-time-first 
(D) small-simple-time-first
(E) shortest-seek-time-front


Answers:
1-Ans. (D)
When handling a page fault, the operating system generally tries to make the required page accessible at the location in physical memory, or terminates the program in case of an illegal memory access.
2-Ans. (A)
Segmentation : Computer memory is allocated in various sizes (segments) depending on the need for address space by the process. These segments may be individually protected or shared between processes.
3-Ans. (C)
Seek time measures the time it takes the head assembly on the actuator arm to travel to the track of the disk where the data will be read or written.
4-Ans. (B)
Some Operating Systems periodically look for pages that have not been recently referenced and add them to the Free page queue, after paging them out if they have been modified.
5-Ans. (B)
A relocatable program is one that can be read into memory at any address and executed without modification.
6-Ans. (A)
It is at the linking time when the externally defined symbol using extdef is resolved. It is because at this time the programs are combined as one and then the real execution starts
7-Ans. (B)
Relocation bits used by relocating loader are specified by Linker
8-Ans. (B)
Virtual Memory is used in all major commercial operating systems.
9-Ans. (A)
Before proceeding with its execution, each process must acquire all the resources it needs is called Hold and Wait.
10-Ans. (A)
SSTF is a secondary storage scheduling algorithm to determine the motion of the disk’s arm and head in servicing read and write requests.

No comments:

Post a Comment