Computer Science 422/622 Quiz B Name _____________________ 1. For each of the following resources identify the deadlock prevention mechanism that was described in class as being used in the "real world" ___ a. OS internal locks. 1. Declare resource sharable ___ b. Memory 2. Use hierarchical allocation 3. Use preemption 4. Require simultaneous allocation 2. We described 4 conditions that were associated with deadlock occurence. (To refresh your memory... one of them was "Hold and Wait".) In order to guarantee that a deadlock over a resource can't occur it is NECESSARY to: a. Make sure that at least b. Make sure that all four one of the four conditions of the conditions can't can't hold. hold. c. Make sure that at least three of the four conditions can't hold. 3. A DEADLOCK always involves a. Exactly two processes b. Exactly three processes b. Either two or one processes d. Two or more processes. 4. In the resource allocation graph approach to deadlock detection a deadlock exists: a. <==> a knot exists in a b. <==> a knot exists in a single unit graph and <==> single unit graph and <==> a knot exists in a mulit-unit a cycle exists in a mulit-unit graph. graph. c. <==> a cycle exists in a d. <==> a cycle exists in a single unit graph and <==> single unit graph and <==> a cycle exists in a mulit-unit a knot exists in a multi-unit graph. graph. 5. Does the following graph include a deadlock? a. yes b. no