In: Computer Science
Processor/CPU Management
I. Five processes, J1, J2, J3, J4 and J5. arrive in the Ready Queue in sequence, one second apart. Each job takes 1 millisecond to load into memory. Each job will take 10, 2, 3, 1, 5 seconds to run respectively. Questions
A. Create a Google Sheet where each column represents a Job and reach row represents a second..
B. Show the state of the Ready Queue in the 7th second, the 11th second and the 20th second using the First Come, First Served, Shortest Job Next, Shortest Remaining Time First, amd Round Robin with time quantum of 2 seconds.
C. Which one is most efficient? Discuss advantage and disadvantage. Double spaced, one pag
Here i am assuming that time starts from 1s. Each job is taking 1s to load into memory.In that case,J1 will be loaded into memory at 2s,J2 at 3s.J3 at 4s ,J4 at 5s and J5 at 6s.These are the arrival time we are considering.
Ready queue consists of processes which are ready to be run but not allotted for processing.For example when J1 is executing and all other processes are ready to run ,ready queue consists of J2,J3,J4,and J5.
For each algorithm, the google sheet image is attaching herewith.
Round robin may produce the lowest waiting time, which may be taken as best in view of waiting time.Shortest job remaining first is also good,but if the number of short processes are higher, longer process still have to wait even if we are taking the remaining shortest time.
My roughwork calculations also i am attaching here for your reference.