CSCI / CMPE 4334 Operating Systems

CSCI / CMPE 4334 Operating Systems

<p> CSCI / CMPE 4334 Operating Systems Quiz (3 Questions)</p><p>Student Name: ______</p><p>Student ID: ______</p><p>Student E-mail: ______</p><p>1. Consider the following preemptive priority-scheduling algorithm based on dynamically changing priorities. Larger priority numbers imply higher priority (note: this is opposite from the priority definition in our lecture slides). When a process is waiting for the CPU (in the ready list, but not running), its priority changes at a rate α; when it is running, its priority changes at a rate β. All the processes are given a priority of 0 when they enter the ready list. The parameters α and β can be set to give different scheduling algorithms. a. What is the algorithm that results from β > α > 0? b. What is the algorithm that results from α < β < 0?</p><p>1 2. Explain the differences in the degree to which the following scheduling algorithms discriminate in favor of short processes: a. First-Come-First-Served b. Round-Robin c. Multilevel feedback queues</p><p>2 3. Suppose that there are five processes in a system, their service time and arrival time are given below: Process Arrival time Service time P1 0 7 P2 0 20 P3 5 5 P4 7 10 P5 8 4 a. Draw the Gantt chart and compute average waiting time for the following methods. Here the waiting time of a process includes all the times it is in the ready list. Assume the context switching time is neglible. 1. First-Come-First-Served 2. Shortest-Job-Next (non-preemptive) 3. Shortest-Remaining-Job-Next 4. Round-Robin with time quantum of 2 5. Round-Robin with time quantum of 4 b. Based on your results, answer the following questions: 1. Among the above methods, which ones are preemptive scheduling methods? 2. Which one gives the shortest average waiting time? Justify your answer.</p><p>3</p>

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    3 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us