COSC 4330 MIDTERM 7/28/98 Closed Book. You can have one sheet of notes. 1. For each of the statements below, indicate in one sentence whether the statement is true or false (2 points), and why (3 points). (a) The First Come First Served policy minimizes the average waiting time of all processes. (b) Time-sharing systems are not true real-time systems. (c) It is a good idea to increase the priority of CPU-bound processes. (d) In a multiprogramming system, there can be many programs in the system but there is never more than a single process. (e) Programs that transfer entire files from one machine to another should use datagrams rather than streams. (f) Accessing a disk drive is 1,000 times slower than accessing the main memory. 2 Answer in one sentence or less to each of the following questions (5 points) (a) What is the value returned by the wait() system call? (b) Give one good reason for a process to interrupt itself: (c) Can you simulate a non-blocking receive using blocking receives? (d) What is the major disadvantage of layered kernels? 3. What is the major advantage of kernel-supported threads over user- level threads ? ( 10 points) 4. What is the major motivation for swapping processes out? (5 points) What can you do to avoid excessive swapping? (5 points) 5 What events will increase or decrease the priority of a process in VMS and by how much?(10 points) 6. What does the scheduling policy of UNIX System V.4 do to avoid process starvation? (10 points) 7. How would you select the time slice in a Round Robin scheduling policy? (10 points) --IMPORTANT----IMPORTANT----IMPORTANT----IMPORTANT----IMPORTANT-- Please do not try to answer these questions by yourself BEFORE having a clear idea of what's on the test for which you are studying. Materials covered in each test DO VARY from semester to semester because the pace of the course can change, some materials are be added and other deleted almost every semester. ----------------------------------------------------------------