Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

java pgm please provide source code and screenshot You are to implement a simple uni-processor scheduling simulator. Your simulator will step through a sequence of

java pgm

please provide source code and screenshot

image text in transcribed

You are to implement a simple uni-processor scheduling simulator. Your simulator will step through a sequence of time units, performing the actions of a simple operating system scheduler The main input to your simulator will be a file containing process-information. Each line in the file wil be of the form Arrive Priority CPU Time Examples: process that arrives at time 10, has a priority of 5 and has 10 5 8 process that arrives at time 12, has a priority of 8 and has 12 8 72 An example of a complete input file is given below. It one CPU burst of duration 8: a CPU burst of duration 72: contains each of the above three processes with first line containing a single value indicating how many processes there are 10 5 8 12 8 72 15 2 7 Some helpful notes/limitations: Arrival times will be strictly increasing in the input file 2) Your program should accept any valid input file 3) There will be at most 100 processes. 4) Lower numbers imply higher priority, with the highest priority a 0 and the lowest priority a 9 Your scheduler should be a preemptive priority scheduler with round-robin as a secondary scheduling criteria. The best solution will allow the user to vary the time quantum but a default of 2 should be used for quantum. Include enough output of your program to show processes being dispatched, preempted, completed, etc. At the end of the simulation, output the turnaround time for each process as wel as average turnaround time. Provide an electronic version of your program source You are to implement a simple uni-processor scheduling simulator. Your simulator will step through a sequence of time units, performing the actions of a simple operating system scheduler The main input to your simulator will be a file containing process-information. Each line in the file wil be of the form Arrive Priority CPU Time Examples: process that arrives at time 10, has a priority of 5 and has 10 5 8 process that arrives at time 12, has a priority of 8 and has 12 8 72 An example of a complete input file is given below. It one CPU burst of duration 8: a CPU burst of duration 72: contains each of the above three processes with first line containing a single value indicating how many processes there are 10 5 8 12 8 72 15 2 7 Some helpful notes/limitations: Arrival times will be strictly increasing in the input file 2) Your program should accept any valid input file 3) There will be at most 100 processes. 4) Lower numbers imply higher priority, with the highest priority a 0 and the lowest priority a 9 Your scheduler should be a preemptive priority scheduler with round-robin as a secondary scheduling criteria. The best solution will allow the user to vary the time quantum but a default of 2 should be used for quantum. Include enough output of your program to show processes being dispatched, preempted, completed, etc. At the end of the simulation, output the turnaround time for each process as wel as average turnaround time. Provide an electronic version of your program source

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Basics Computer EngineeringInformation Warehouse Basics From Science

Authors: Odiljon Jakbarov ,Anvarkhan Majidov

1st Edition

620675183X, 978-6206751830

More Books

Students also viewed these Databases questions

Question

4. examine the process of psychological self-regulation,

Answered: 1 week ago

Question

What is meant by 'Wealth Maximization ' ?

Answered: 1 week ago

Question

10-9 How have social technologies changed e-commerce?

Answered: 1 week ago