Assignment 6: Scheduling

Problem:

Design a cpu scheduler of  your own choice.(not FCFS)
You have to (1) compute various performance measures (turnaround time,
waiting time, penalty ratio for each process and system averages and system throughput)
(2) analyze the behavior of your scheduler.

Process data is to be read in from a file in a standard format. 
Assume that there is only one CPU and one I/O device in the system. The I/O device can be assumed to be sequential ie. it serves only one process at a time.

Test Data:

Test process data files have the following format:

0 100 2 200 3 25 -1    i.e.  P1 : arrival time (0)  CPU burst (100) I/O burst (2) .. CPU burst (25)
5 6 2 25 2 25 2 25 -1        P2 : arrival time (5)  ....
Assume that every line ends with -1

The arrival times are in nondecreasing order

A process may have any number of CPU / I/O burst cycles terminated with a -1.
There will be any number of processes, terminated by an end of file . 

An example  process data file

The test cases:

process1.dat
process2.dat
process3.dat
 
 

Note:

Submission

Submit your .c (or any file) file using ~oslab/submit script as in: ~oslab/submit 6 myfile.c
submit script accepts assignment no. in its first argument. Any number of files may be submitted through subsequent arguments.
You may submit any number of times before 6:00pm. Old files are overwritten in resubmission.
In case of any problem with submission, pls mail your assignments to subash@cse.iitb.ac.in

Deadline: 6:00pm