Skip to content

GATE CS Operating System questions

Practise Operating System questions for GATE CS. Explore official PYQs and original subject-wise quizzes, check answers and view available solutions. Free, no sign-in.

Trace the state changes explicitly. For scheduling, memory and synchronisation questions, record the given policy before calculating the result.

Subject, topic, year and type filter the full library. Match any choice within a filter, and all selected filter categories. Search, source and sort apply to this page.

20 on this page
Official PYQ2006Operating SystemConcurrency and SynchronizationMCQ · 1 mark
Barrier is a synchronization construct where a set of processes synchronizes globally i.e., each process in the set arrives at the barrier and waits for all others to arrive and then all processes leave the barrier. Let the number of processes in the set be three and SS be a binary semaphore with the usual PP and VV functions. Consider the following …
Official PYQ2006Operating SystemConcurrency and SynchronizationMCQ · 1 mark
Barrier is a synchronization construct where a set of processes synchronizes globally i.e., each process in the set arrives at the barrier and waits for all others to arrive and then all processes leave the barrier. Let the number of processes in the set be three and SS be a binary semaphore with the usual PP and VV functions. Consider the following …
Official PYQ2006Operating SystemDeadlockMCQ · 1 mark
Consider the following snapshot of a system running nn processes. Process ii is holding xix_i instances of a resource RR, 1≤i≤n1\leq i\leq n . Currently, all instances of RR are occupied. Further, for all ii, process ii has placed a request for an additional yiy_i instances while holding the xix_i instances it already has. There are …
Official PYQ2006Operating SystemCPU SchedulingMCQ · 1 mark
Consider three processes, all arriving at time zero, with total execution time of 1010, 2020 and 3030 units, respectively. Each process spends the first 20%\text{20\%} of execution time doing I/O, the next 70%\text{70\%} of time doing computation, and the last 10%\text{10\%} of time doing I/O again. The operating system uses a shortest remaining …
Official PYQ2006Operating SystemMemory Management and Virtual MemoryMCQ · 1 mark
A computer system supports 3232-bit virtual addresses as well as 3232-bit physical addresses. Since the virtual address space is of the same size as the physical address space, the operating system designers decide to get rid of the virtual memory entirely. Which one of the following is true?
Official PYQ2006Operating SystemCPU SchedulingMCQ · 1 mark
Consider three processes (process id 00, 11, 22 respectively) with compute time bursts 22, 44 and 88 time units. All processes arrive at time zero. Consider the longest remaining time first (LRTF) scheduling algorithm. In LRTF ties are broken by giving priority to the process with the lowest process id. The average turn around time is:
Official PYQ2006Operating SystemMemory Management and Virtual MemoryMCQ · 1 mark
A CPU generates 3232-bit virtual addresses. The page size is 44 KB. The processor has a translation look-aside buffer (TLB) which can hold a total of 128128 page table entries and is 44-way set associative. The minimum size of the TLB tag is:
Official PYQ2006Operating SystemConcurrency and SynchronizationMCQ · 1 mark
The atomic fetch-and-set x,yx, y instruction unconditionally sets the memory location xx to 11 and fetches the old value of xx in yy without allowing any intervening access to the memory location xx. Consider the following implementation of PP and VV functions on a binary semaphore SS. void P (binary_semaphore *s) { unsigned y; …
Official PYQ2006Operating SystemCPU SchedulingMCQ · 1 mark
Consider three CPU-intensive processes, which require 1010, 2020 and 3030 time units and arrive at times 00, 22 and 66, respectively. How many context switches are needed if the operating system implements a shortest remaining time first scheduling algorithm? Do not count the context switches at time zero and at the end.
Official PYQ2005Operating SystemDeadlockMCQ · 1 mark
Suppose nn processes, P1,…PnP_1, \dots P_n share mm identical resource units, which can be reserved and released one at a time. The maximum resource requirement of process PiP_i is sis_i, where si>0s_i > 0. Which one of the following is a sufficient condition for ensuring that deadlock does not occur?
Official PYQ2005Operating SystemMemory Management and Virtual MemoryMCQ · 1 mark
Increasing the RAM of a computer typically improves performance because:
Official PYQ2005Operating SystemI/O SchedulingMCQ · 1 mark
What is the swap space in the disk used for?
Official PYQ2005Operating SystemI/O SchedulingMCQ · 1 mark
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 instruction 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?
Official PYQ2005Operating SystemI/O SchedulingMCQ · 1 mark
Which one of the following is true for a CPU having a single interrupt request line and a single interrupt grant line?
Official PYQ2005Operating SystemSystem CallsMCQ · 1 mark
Consider the following code fragment: if (fork() == 0) { a = a + 5; printf("%d, %p n", a, &a); } else { a = a - 5; printf ("%d, %p n", a,& a); } Let u,vu,v be the values printed by the parent process and x,yx,y be the values printed by the child process. Which one of the following is TRUE?
Official PYQ2004Operating SystemI/O SchedulingMCQ · 1 mark
A unix-style I-nodes has 1010 direct pointers and one single, one double and one triple indirect pointers. Disk block size is 11 Kbyte, disk block address is 3232 bits, and 4848-bit integers are used. What is the maximum possible file size?
Official PYQ2004Operating SystemCPU SchedulingMCQ · 1 mark
Consider the following set of processes, with the arrival times and the CPU-burst times gives in milliseconds. …
Official PYQ2004Operating SystemConcurrency and SynchronizationMCQ · 1 mark
Consider two processes P1P_1 and P2P_2 accessing the shared variables XX and YY protected by two binary semaphores SXS_X and SYS_Y respectively, both initialized to 1. PP and VV denote the usual semaphore operators, where PP decrements the semaphore value, and VV increments the semaphore value. The pseudo-code of P1P_1 and P2P_2 …
Official PYQ2004Operating SystemMemory Management and Virtual MemoryMCQ · 1 mark
The minimum number of page frames that must be allocated to a running process in a virtual memory environment is determined by
Official PYQ2004Operating SystemI/O SchedulingMCQ · 1 mark
Consider an operating system capable of loading and executing a single sequential user process at a time. The disk head scheduling algorithm used is First Come First Served (FCFS). If FCFS is replaced by Shortest Seek Time First (SSTF), claimed by the vendor to give 50%50 \% better benchmark results, what is the expected improvement in the I/O performance …