Question: CS2123 Data Structures - Fall 2018 Assignment 3: multilevelQueueScheduler Due 10/8/18 by 11:59pm In this assignment you will be simulating some of the work performed

 CS2123 Data Structures - Fall 2018 Assignment 3: multilevelQueueScheduler Due 10/8/18by 11:59pm In this assignment you will be simulating some of the

CS2123 Data Structures - Fall 2018 Assignment 3: multilevelQueueScheduler Due 10/8/18 by 11:59pm In this assignment you will be simulating some of the work performed by an operating system (albeit at a super high level). Specifically you will track the simulated processes that currently need to run and then schedule them to run on the CPU according to a given set of rules Introduction Each process has: e an 1dentiher a number of time cycles needed to run . an array of data that belongs to that process a priority of either FOREGROUND or BACKGROUNID you can add other data that you think will help in simulating the schedule Code: scheduleProcess (5 points) You are passed a process identifier and priority to add to the appropriate queue Code: simulateTimeStep (10 points) Simulates running one time step of a process. The process to simulate will be chosen based on the following rules (1) As long as there are FOREGROUND tasks no BACKGROUND task is (2) Rules for running FOREGROUND processes: run (a) Store the FOREGROUND processes in a queue (b) The queue follows a round-robin schedule scheme. In particular, after the process at the front of the queue runs for 5 cycles it is moved to the back of the queue (3) Rules for running BACKGROUND processes: (a) Store the BACKGROUND processes in a queue (b) The queue follows a FCFS (first-come, first-serve) schedule scheme In particular, the first process added to the BACKGROUND queue will be fully processed before any of the other processes in the queue arc (c) If a process has remained in the BACKGROUND queue for 50 cycles or longer it is moved to the rear of the FOREGROUND queue

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!