Peterson’s algorithm

Peterson’s algorithm An established algorithm known as Peterson’s algorithm provides the correct solution to critical section problems. In this algorithm, two variables has been defined on array i.e. flag and another turn flag can be initially set to either true of false while turn variable can be set to either 1 or 0. Var flag array [0-1] or Boolean; Turn 0—1 Process A Flag [0] =true; Turn =1; While (flag [1] & turn=1) Do {nothing} <Critical section> Flag [0] =false; Remainder section. Process B Flag [1]...

read more

Dekker’s Algorithm

Dekker’s Algorithm Dijktra reported on algorithm for mutual exclusion for two processes that are design by the Dutch Mathematician Dekker the developing solution in stages. This solution is applicable only when two process are at time let us consider two process p0 and p1 First attempt (algorithm 1):- this method works on the principle of busy waiting i.e. continuously testing the variable and waiting for same value to appear. In this method the two process share common variables “turn” whose initial value can be either ‘0’ or...

read more

Processes Scheduling queue

Processes Scheduling queue

As processes enter the system they put in job queue. This queue consists of all processes of the system, some process is kept on main memory waiting or ready to execute, so they are placed in the list called ready queue. So, each operating system consists of other queues when the process is allocated on its CPU. It executes for a while and eventually quite, is interrupted or waits for some particular events to occur such as I/O request I/O request is dedicated to tape driver or sharing device or disk. As we know that system comparing of number...

read more

process model

process model

The software and large program is organized into a number of sequential processes or process. A process is just executing program including current values of the program counter, register and variables. Each process has its virtual CPU. The CPU switches back and forth from process to process. Suppose four programs running in pseudo parallelism and CPU swit5ches from one program to another as shown in figures below:     From figure (a) four program are in memory in figure (b) them are four processes, each its own flow of control and...

read more

processes creation

processes creation

A process can create several new processes. The creating process is called parent process whereas a new process is called child process of that process. New process can further create a more child processes, thus forming tree structure. Here, a child has only one parent and a parent has more Childs. Every process will need certain resource (CPU, time, memory, I/O devices) to accomplish its work. If any processes create any sub-process that sub-process may use the resources from the operating system or parent may partition its resources among...

read more

Mutual Exclusion of Processes

Mutual Exclusion of Processes

Mutual exclusion is a mechanism to ensure that only one process is doing certain things at one time and other are prevented from modification shared data until the current process finish. *Implementation of mutual exclusion Let us consider an example of “too much pizza” problem There are the process A & B having schedule as shown in figure below. This problem shows that when co-operating processes are not synchronised, they may face unexpected error.  Mutual exclusion mechanism when applied to this problem will ensure that only one...

read more

Process States

Process States

As the program executes, it generally changes state. A state of the process is defined as the current activities of that process. Each process may have one of the following states:- a.  New: – the process is being created. b. Running: – instruction is being executed. c. Waiting: – a process is waiting for some event (e.g. printer during sending signals) or reception of signal between computer and printer. d. Ready: – the processor is ready to execute that particular process. e. Terminated: – the process has...

read more

Introduction to Processes in operating system

  Early computer system allowed any one program to be executed at a base, current days computer system allow multiple program to be loaded in memory and to be executed at the same time or step by step. This executing multiple programs is being resulted as process. A process is the unit of work in a modern time sharing system. In modern system processing consist of processing a collection of processes. Operating system processes executing system code and a user processes executing user code all this process an executed simultaneously by...

read more

supervisor and user mode of operating system

supervisor and user mode: The process is executed in the modes supervisor and user mode. In supervisor mode control programs are executed. Actually in this mode the resource is given to user mode or used in a program. Command interpreter (shell), compiler, editor and similar application independent programs. These programs are not part of operating system but controlled by operating systems. The operating system is that portion of software that runs in kernel mode or supervisor mode. The process or program is kernel mode is mode secure. In...

read more

What is kernel?

Kernel: All the operating involving processes are controlled by a part of operating system called kernel or nucleus or core. In modern operating system the kernel is small portion of operating system but plays very important role in computer system. The kernel is interactive with the user mode or user program. The kernel resides inside primary storage or ram when the computer is opened and controls the system. Other portion of operating system may reside in secondary storage and load in primary memory when needed. The kernel gives services to...

read more
Page 17 of 18« First...10...1415161718