PROCESSES AND THREADS

PROCESSES AND THREADS
1578 views
PROCESSES AND THREADS

We are now about to start a detailed stu`dy of how operating systems are designed and created. The most essential concept in any operating system is the process: an abstraction of

The Process Model
1495 views
The Process Model

In this model, all the runnable software on the computer, sometimes including the operating system, is organized into a number of sequential processes, or just processes for short. A process is just an example of an executing program, including the current values of the program

Process Creation
1456 views
Process Creation

Operating systems require some way to make processes. In very simple systems, or in systems designed for running only a single application (e.g., the controller in a microwave oven), it may be possible to have all the processes that will ever be needed be present when

Process Termination
1435 views
Process Termination

After a process has been created, it starts running and performs whatever its job is. However, nothing lasts forever, not even processes. Sooner or later the new process will end, generally due to one of the following conditions:

Process Hierarchies
1082 views
Process Hierarchies

In some systems, when a process creates another process, the parent process and child process continue to be connected in certain ways. The child process can itself create more processes, forming a process hierarchy. Note that unlike plants and animals that use sexual

Process States
2494 views
Process States

Although each process is an independent entity, with its own program counter and internal state, processes sometimes have to interact with other processes. One process may produce some output that another process uses as input. In the shell command

Implementation of Processes
1646 views
Implementation of Processes

To implement the process model, the operating system maintains a table (an array of structures), called the process table, with one entry per process. (Some authors call these entries process control blocks.) This entry includes important information about the process state,

Modeling Multiprogramming
2873 views
Modeling Multiprogramming

When multiprogramming is used, the CPU utilization can be improved. Crudely put, if the average process computes only 20% of the time it is sitting in memory, with five processes in memory at once, the CPU should be busy all the time. This model is unrealistically hopeful,

THREADS
2127 views
THREADS

In usual operating systems, each process has an address space and a single thread of control. In reality, that is almost the definition of a process. However, there are often situations in which it is desirable to have multiple threads of control in the same address space running in

The Classical Thread Model
4137 views
The Classical Thread Model

Now that we have seen why threads might be helpful and how they can be used, let us examine the idea a bit more closely. The process model is based on two independent ideas: resource grouping and execution. Often it is beneficial to separate them; this is where threads

Page 1 of 4 Previous 1 2 3 4 Next