Performance Analysis of CPU Scheduling Algorithms with Novel OMDRRS Algorithm

CPU scheduling is one of the most primary and essential part of any operating system. It prioritizes processes to efficiently execute the user requests and help in choosing the appropriate process for execution. Round Robin (RR) & Priority Scheduling(PS) are one of the most widely used and acceptable CPU scheduling algorithm. But, its performance degrades with respect to turnaround time, waiting time & context switching with each recurrence. A New scheduling algorithm OMDRRS is developed to improve the performance of RR and priority scheduling algorithms. The new algorithm performs better than the popular existing algorithm. Drastic improvement is seen in waiting time, turnaround time, response time and context switching. Comparative analysis of Turn around Time(TAT), Waiting Time(WT), Response Time (RT) is shown with the help of ANOVA and t-test. Keywords—Round Robin; Turn-around time; Waiting Time; ttest; Anova test


INTRODUCTION
CPU scheduling is similar to other types of scheduling, which have been studied over the years.CPU scheduling refers to the decision of allocating a single resource among multiple clients.It also tracks the order of allocation and duration.The primary objective of scheduling is to optimize system performance.Optimization system is considered as most de¬emed criteria by the system designers [1].There are numerous algorithms for CPU Scheduling with distinct benefits and shortcomings.To understand and comprehend them in detail, they need to be simulated and performance indices must be studied.This paper depicts the usability of different scheduling algorithms, compare them on the basis of different performance criteria and introduce a newly designed improvised RR scheduling algorithm(OMDRRS).OMDRRS "An Optimum Multilevel Dynamic Round Robin Scheduling Algorithm" is a simulator that has been successfully implemented using VB6.0.The simulator demonstrates the algorithm behavior in opposition to a simulated mix of process loads.The results of all algorithms are compared for the scheduling criteria like turnaround time, waiting time, response time and context switch etc.

A. Scheduling Criteria
Schedulers use different scheduling criteria to enhance the performance of CPU.
Utilization/Efficiency: CPU should be best utilized by allocating the significant tasks; so that it should not be ideal.

Throughput:
To increase the number of processed jobs per hour.
Turnaround time: Total time taken from submission of the process till the completion.Turnaround time should minimize the time of users who wait for the output.
Waiting time: Should be minimized as it is the total time spent in ready queue Response Time: Is the duration after submission till the response.It should be minimal in case of interactive users.
Fairness: CPU should be unbiased and every process should get its fair time to execute.

B. Organization of the Paper
This paper is divided into four sections.Section I gives a brief introduction on the various aspects of the scheduling algorithms, the approach of the current paper and the motivational factors leading to this improvement.Section II presents the hypothesis of study, research methodology, data collection, methods used and the pseudo code of Dynamic Round Robin Algorithm (OMDRRS).In Section III, an experimental analysis and Result of our algorithm OMDRRS and its comparison with the RR algorithm, Priority scheduling and FCFS algorithm is presented.Conclusion and future scope is presented in Section IV.

II. OBJECTIVE
The objective of the study is to compare the performances of different CPU scheduling Algorithms with OMDRRS.

A. Hypothesis of Study
The main or the principal instrument in the research is hypothesis.Its main factors are to suggest new experiments and observations.A number of experiments have been conducted with the deliberate objective of testing the hypothesis.

B. Research Methodology  Sample Size
The sample size is taken as 50.

C. Data Collection Method
Primary data is entered through the designed simulator by 50 respondents and performance of various CPU Scheduling algorithms is calculated on each of them.

D. Choice of Respondents
The study focused upon the performance analysis of various CPU Scheduling algorithms.The respondents were filtered on the basis of their knowledge on operating systems and CPU scheduling algorithms.

E. Simulator
The purpose of designing the simulator was to provide exactly the same processes to all CPU Scheduling Algorithms for performance comparison without any variations.The simulator was implemented to simulate the operations of First Come First Serve, Shortest Job First(Non Preemptive & Preemptive), Highest Priority, Round Robin and Improved Round Robin scheduling algorithms.These algorithms were implemented in order to establish a valid premise for effective comparison.Simulator has two operating modes: Manual Process Entry and Automatic Process Generator.In Automatic Process Generator system, it fetches all the active processes with burst time and assumes that all the processes were arrived at same arrival time and have no priority.Whereas in the manual entered process, user enters the burst time as per their requirement, as well as arrival time and priority of the each process.In this study respondents entered primary data in manual mode.Based on the selected scheduling algorithm, the average turnaround time, average waiting time, response time, context switch and Gantt chart were calculated.The simulation was run several times to ensure fairness to all datasets each algorithm is evaluated using Average Turn-around Time, Average Waiting Time, Response Time and Gantt chart as the performance evaluation indices.

F. Proposed Algorithm
The proposed algorithm [8] combines the working principle of fundamental scheduling algorithms.Dynamically Time Slice (DTS) is calculated which allocates different time quantum for each process based on priority, shortest CPU burst time and context switch avoidance time.
Step 1: Compute the factor analysis F= Burst time * 0.2 + Arrival time * 0.3 + Priority of the process * 0.5 Step 2: Shuffle the processes in ascending order according to the factor of each process in the ready queue (RQ) such that the head of the ready queue contains the lowest factor process based on the burst time, arrival time & priority of the process.

G. Time Complexity of OMDRRS Algorithm
The OMDRRS algorithm would be maintaining all jobs based on the factor analysis that is ready for execution in a queue.Insertion of each job will be achieved in O(1), but deletion would require O(n) time, where n is the number of processes in the queue.Whenever a process arrives, a record for it can be inserted into the queue based on its burst time, arrival time and priority in O(n) time, where n is the number of processes in the queue.Thus, the time complexity of OMDRRS is equal to that of a typical linear sorting algorithm which is O(n).If a new task arrives it is then sorted with the remaining processes and then executed in the same way.To find a task with the lowest burst time the scheduler needs to search in the ready queue, then the order of searching would be O(n).www.ijacsa.thesai.org

H. Logic Diagram of OMDRRS Algorithm
III. DATA ANALYSIS METHOD Burst time, Arrival time and Priority of the processes were filled by 50 respondents in developed simulator.The simulator generated results of various scheduling algorithms and novel OMDRRS which were further analyzed and compared with anova and t-test.

 Ethical Considerations
The author didn't modified the existing CPU scheduling algorithm concepts and implemented them as it is in the simulator with the new version of round robin algorithm i.e.OMDRR.

A. Experimental Analysis
Fifty processes have been defined by CPU burst time, arrival time and priority of the processes.These fifty processes are scheduled in first come first serve, shortest job first, priority scheduling, round robin scheduling and also in the proposed algorithm.The turnaround time and waiting time have been calculated through simulator and the results were compared.

B. Results of Analysis
In order to analyze the difference in performance of the various CPU scheduling algorithms, ANOVA and t-test are used and the following results are obtained as follows:          The confidence interval for execution time of turnaround time of various scheduling algorithms at 95% shows that the time is varying between 231.46 nanoseconds to 454.37 nanoseconds that is 95% of the jobs will complete its execution within this time frame.

IV. CONCLUSION AND FUTURE SCOPE
This paper statistically analyzes and compares various scheduling algorithms with proposed algorithm.It analysis the performance of various CPU scheduling algorithms with respect to dynamic time slice concept in Round Robin CPU scheduling.The suggested algorithm and other scheduling algorithm are executed on the simulator and evaluated on Anova and t-test.The Results clearly depicts that OMDRRS performs better than existing algorithms on the basis of Anova and t-test results comparative analysis of Turnaround time, waiting time & context switch clearly shows that OMDRRS gives much better turnaround time with very less waiting time.Deterministic statistics shows that the confidence index is improved in the case of OMDRRS algorithm.Results concludes that the proposed algorithm is superior then commonly used algorithm with less waiting response time, less turnaround time and context switching; thereby reducing the overhead and results in saving lots of memory space.Taking the base of proposed algorithm more improvement can be made the future.

TABLE I .
CALCULATED TURNAROUND TIME OF FCFS, SJF(NP), SJF, PS, RR AND OMDRRS ALGORITHM THROUGH SIMULATOR TABLE II.CALCULATED WAITING TIME OF FCFS, SJF(NP), SJF, PS, RR AND OMDRRS ALGORITHM THROUGH SIMULATOR

TABLE III .
COMPARISON OF TURNAROUND TIME IN FCFS, SJF(NP), SJF, PS, RR AND OMDRRS ALGORITHMIn the above table of ANOVA turnaround time is significantly differ for different scheduling algorithms, because the computed value (F) is greater than tabulated value (F crit) at 5% level of significance.Hence H0 1.1 is rejected.Rejecting null hypothesis proves that there is significant difference in Turnaround time of various CPU Scheduling Algorithms.

TABLE IV .
COMPARISON OF WAITING TIME IN FCFS, SJF(NP), SJF, PS, RR AND OMDRRS ALGORITHMIn the above table of ANOVA shows that overall waiting time is significant.Since the computed value (F) is greater than tabulated value (F crit) at 5% level of significance.Hence H01.2 is rejected.Rejecting null hypothesis proves that there is significant difference in waiting time of various CPU Scheduling Algorithms.

TABLE V .
COMPARISON OF RESPONSE TIME IN FCFS, SJF(NP), SJF, PS, RR AND OMDRRS ALGORITHM

TABLE VI .
COMPARISON OF TURN AROUND TIME BETWEEN PRIORITY SCHEDULING AND DYNAMIC ROUND ROBIN ALGORITHM WITH THE HELP OF

TABLE VII .
COMPARISON OF TURN AROUND TIME BETWEEN ROUND ROBIN SCHEDULING AND DYNAMIC ROUND ROBIN ALGORITHM WITH THE HELP OF T-TEST

TABLE VIII .
COMPARISON OF WAITING TIME BETWEEN PRIORITY SCHEDULING AND DYNAMIC ROUND ROBIN ALGORITHM WITH THE HELP OF T-TEST At 5% level of significance h11.2 is rejected hence there is a significant difference between waiting time of Priority Scheduling and Dynamic Round Robin Algorithm.Above table proves that Proposed algorithm OMDRRS is better than the Priority scheduling algorithm in terms of waiting time.

TABLE IX .
COMPARISON OF WAITING TIME BETWEEN ROUND ROBIN SCHEDULING AND DYNAMIC ROUND ROBIN ALGORITHM WITH THE HELP OF T-TEST At 5% level of significance h11.2 is rejected hence there is a significant difference between waiting time of Round Robin Scheduling and Dynamic Round Robin Algorithm.Hence OMDRRS is also better than the round robin scheduling algorithm.

TABLE XI .
COMPARISON OF TURNAROUND TIME BETWEEN ROUND ROBIN SCHEDULING AND DYNAMIC ROUND ROBIN ALGORITHM WITH THE HELP OF T-TEST At 5% level of significance h11.1 is rejected hence there is a significant difference between turnaround time of Round Robin Scheduling and Dynamic Round Robin Algorithm.Above table proves that our proposed algorithm OMDRRS is better than the Round Robin scheduling algorithm in terms of turnaround time.

TABLE XII .
DETERMINISTIC STATISTICS OF VARIOUS SCHEDULING ALGORITHM