Sunteți pe pagina 1din 3

Synopsis Of CSE:310

Topic: Process Scheduling Algorithms

Submitted To: Mr. Sawal Tandan

Submitted By: Vinod Kumar Verma Sec: RKE123B19 Reg.No.:10804863

Implemented the following Scheduling algorithms: First Come First Serve (FCFS) Round Robin Shortest Job First Shortest Remaining Time

First Come First Serve (FCFS) This non-preemptive scheduling algorithm follows the first-in, first-out (FIFO) policy. As each process becomes ready, it joins the ready queue. When the current running process finishes execution, the oldest process in the ready queue is selected to run next. Round Robin (RR) RR is designed specially for time-sharing systems. It is similar to FCFS but preemption is added to switch between processes. A small unit of time, called a time quantum or time slice, is defined. The ready queue is treated as a circular queue. The CPU scheduler goes around the ready queue, allocating the CPU to each process for a time interval of up to 1 time quantum.

The implementation of RR is easily managed with a FIFO ready queue. The CPU is allocated to the process at the head the ready queue. Then, one of two things will happen. If the process has a CPU burst of less than 1 time quantum, the process itself will release the CPU voluntarily. The CPU is then assigned to the next process in the ready queue. Otherwise, if the CPU burst of the currently running job is longer than 1 time quantum, the process is preempted after 1 time quantum and put at the tail of the ready queue. The CPU is then assigned to the next process in the ready queue. Shortest Job First (SJF) This non-preemptive scheduling algorithm favors processes with the shortest expected process time. As each process becomes ready, it joins the ready queue. When the current running process finishes execution, the process in the ready queue with the shortest expected processing time (or service time) is selected to run next. Shortest Remaining Time (SRT) This preemptive scheduling algorithm favors processes with the shortest remaining expected process time. As each process becomes ready, it joins the ready queue. This triggers an interrupt which preempts the current running process back into the ready queue. The process in the ready queue with the shortest remaining service time is selected to run next.

Selection of JAVA as a programming tool Rich GUI classes available (Swing, AWT) Object Orientation capabilities Convenient and powerful documentation capabilities AWT: Abstract Windows Toolkit (AWT) is the original Java GUI tool kit. AWT's main advantages are that it comes standard with every version of Java technology, including Java implementations in old Web browsers, and it is very stable. This means you do not need to install it, you can depend on it being available everywhere you find a Java runtime environment, and it will have the features you expect. AWT is a very simple tool kit with limited GUI components, layout managers, and events (see Listing 1, Listing 2 and Listing 3). This is because Sun Microsystems decided to use a lowest-common denominator (LCD) approach for AWT. Only GUI components defined for all Java host environments would be used. As a result -- and unfortunately -- some commonly used components, such as Tables, Trees, Progress Bars, and others, are not supported. For applications that need more component types, you need to create them from scratch. This is a big burden.

AWT features include:


A rich set of user interface components. A robust event-handling model. Graphics and imaging tools, including shape, color, and font classes. Layout managers, for flexible window layouts that don't depend on a particular window size or screen resolution. Data transfer classes, for cut-and-paste through the native platform clipboard.

SWING: Java Swing, also known as a part of the Java Foundation Classes (JFC), was an attempt to solve most of AWT's shortcomings. In Swing, Sun created a very well-engineered, flexible, powerful GUI tool kit. Unfortunately, this means Swing takes time to learn, and it is sometimes too complex for common situations. Swing is built on parts of AWT. All Swing parts are also AWT parts. Swing uses the AWT event model and support classes, such as Colors, Images, and Graphics. The Swing components, layout managers, and events are summarized below.As you can see, these sets are far more extensive than that supplied by AWT and compares well to the SWT set.

Swing features include:


All the features of AWT. 100% Pure Java certified versions of the existing AWT component set (Button, Scrollbar, Label, etc.). A rich set of higher-level components (such as tree view, list box, and tabbed panes). Pure Java design, no reliance on peers. Pluggable Look and Feel.

S-ar putea să vă placă și