Kingdom of Saudi Arabia بسم هللا الرحمن الرحيم Ministry of Higher Education Majmaah University College Of Sciences in Alzulfi -:المستوى -:رقم ورمز المادة 1436/7/8 -:تاريخ اإلمتحان الـمـمـلكـة الـعـربـيـة الـسـعـوديـة وزارة الـتـعـلـيـم الـعـالـي جـامـعـة الـمـجـمـعـة كلية العلوم بالزلفي نظم التشغيل -:الرقم الجامعي -:اسم المادة -:اسم الطالب Answer the following questions: Question 1: Complete the following sentences: 1. Low priority processes may never execute if it suffers from a____________ problem that can be solved by ______________ 2. _____________ prevents sets of concurrent processes from completing their tasks. 3. __________number of processes that complete their execution per time unit. 4. In Resource Allocation Graph, we ensure that there is no deadlock if _________ 5. The two registers used to define logical addresses are _________ and _________ registers. 6. _____________ are the addresses generated by the CPU and the ___________ address seen by the memory unit. Question 2: Select the best answer 1. ________________ is the amount of time process takes from when a request was submitted until the first response is produced. a. Turnaround time b. Response time. c. Waiting time. d. Utilization time 2. The amount of time a process has been waiting in the ready queue is known as ______________. a. Turnaround time b. Response time. c. Waiting time. d. Utilization time 1 Kingdom of Saudi Arabia بسم هللا الرحمن الرحيم Ministry of Higher Education Majmaah University College Of Sciences in Alzulfi -:المستوى -:رقم ورمز المادة 1436/7/8 -:تاريخ اإلمتحان الـمـمـلكـة الـعـربـيـة الـسـعـوديـة وزارة الـتـعـلـيـم الـعـالـي جـامـعـة الـمـجـمـعـة كلية العلوم بالزلفي نظم التشغيل -:الرقم الجامعي -:اسم المادة -:اسم الطالب 3. The scheduling algorithm that cannot be preemptive is _____________ a. First Come First Served. b. Shortest Job First. c. Round Robin. d. All of above. 4. If the wait for graph contains a cycle __________: a. then a deadlock does not exist b. then a deadlock exists c. then the system is in a safe state d. either b or c 5. A deadlock eventually damages system throughput and will cause the CPU utilization to _____. a. increase b. drop c. stay still d. None of these 6. In wait-for-graph an arrow from Pi to Pj means: a. Pi is waiting for Pj to release a resource that Pi needs b. Pj is waiting for Pi to release a resource that Pj needs c. Pi is waiting for Pj to leave the system d. Pj is waiting for Pi to leave the system 2 بسم هللا الرحمن الرحيم Kingdom of Saudi Arabia Ministry of Higher Education Majmaah University College Of Sciences in Alzulfi -:المستوى -:رقم ورمز المادة 1436/7/8 -:تاريخ اإلمتحان -:الرقم الجامعي Question 3: Consider we have 4 processes P0 through P3; 3 resource types: A (11 instances), B (10instances), and C (6 instances) A snapshot at time t0 of a system P0 P1 P2 P3 Allocation ABC 301 221 312 051 Max ABC 511 321 332 461 Available A B C 3 2 1 Using the banker's algorithm to: a. find the need matrix. b. Is the system in safe or unsafe state. c. If it will be safe illustrate the sequence of execution. d. Can request for (2,1,0) by P3 be granted? Ans. a. Need A B C P0 P1 P2 P3 3 الـمـمـلكـة الـعـربـيـة الـسـعـوديـة وزارة الـتـعـلـيـم الـعـالـي جـامـعـة الـمـجـمـعـة كلية العلوم بالزلفي نظم التشغيل -:اسم المادة -:اسم الطالب