GATE CS Deadlock questions
Practise Deadlock questions for GATE CS. Explore official PYQs and original topic-wise quizzes, check answers and view available solutions. Free, no sign-in.
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
With respect to deadlocks in an operating system, which of the following statements is/are FALSE?
Consider a system consisting of instances of a resource , being shared by processes. Assume that each process requires a maximum of two instances of resource and a process can request or release only one instance at a time. Further, a process can request the second instance of the resource only after acquiring the first instance. The …
consists of all active processes in an operating system. consists of single instances of distinct types of resources in the system. The resource allocation graph has the following assignment and claim edges. Assignment edges: …
Which of the following statements is/are with respect to deadlocks?
Consider a computer system with multiple shared resource types, with one instance per resource type. Each instance can be owned by only one process at a time. Owning and freeing of resources are done by holding a global lock . The following scheme is used to own a resource instance: function OWNRESOURCE(Resource R) Acquire lock L // a global lock if R …
Consider the following snapshot of a system running concurrent processes. Process is holding instances of a resource , . Assume that all instances of are currently in use. Further, for all , process can place a request for at most additional instances of while holding the …
In a system, there are three types of resources: and . Four processes , , and execute concurrently. At the outset, the processes have declared their maximum resource requirements using a matrix named Max as given below. For example, Max[] is the maximum number of instances of that would …
Consider a system with processes that share instances of the same resource type. Each process can request a maximum of instances. Resources can be requested and releases only one at a time. The largest value of that will always avoid deadlock is ___
A system shares tape drives. The current allocation and maximum requirement of tape drives for that processes are shown below: …
A system has identical resources and processes competing for them. Each process can request at most resources. Which one of the following values of could lead to a deadlock?
Consider the following policies for preventing deadlock in a system with mutually exclusive resources. Process should acquire all their resources at the beginning of execution. If any resource is not available, all resources acquired so far are released. The resources are numbered uniquely, and processes are allowed to request for resources only in …
An operating system uses the Banker's algorithm for deadlock avoidance when managing the allocation of three resource types and to three processes and The table given below presents the current system state. Here, the Allocation matrix shows the current number of resources of each type allocated to each process and the Max …
A system contains three programs and each requires three tape units for its operation. The minimum number of tape units which the system must have such that deadlocks never arise is _________.
Three concurrent processes , , and execute three different code segments that access and update certain shared variables. Process executes the operation (i.e., ) on semaphores , and ; process executes the operation on semaphores , and ; process executes the …
A system has resources , and processes . The implementation of the resource request logic of each process is as follows: …
Consider a system with types of resources ( units), ( units), ( units), ( units). A non-preemptive resource allocation policy is used. At any given instance, a request is not entertained if it cannot be completely satisfied. Three processes , , request the resources as follows if …
Which of the following is NOT true of deadlock prevention and deadlock avoidance schemes?
A single processor system has three resource types and , which are shared by three processes. There are units of each resource type. Consider the following scenario, where the column alloc denotes the number of units of each resource type allocated to each process, and the column request denotes the number of units of each resource type …
Consider the following snapshot of a system running processes. Process is holding instances of a resource , . Currently, all instances of are occupied. Further, for all , process has placed a request for an additional instances while holding the instances it already has. There are …
Suppose processes, share identical resource units, which can be reserved and released one at a time. The maximum resource requirement of process is , where . Which one of the following is a sufficient condition for ensuring that deadlock does not occur?
