Process and Threads

Get Started. It's Free
or sign up with your email address
Process and Threads by Mind Map: Process and Threads

1. Five-State Process Model

1.1. Figure

2. Operating System Control Structures

2.1. OS must have information about the current status

2.2. OS constructs and maintains tables of information about each entity that it is managing.

2.3. Four different types of tables maintained by the OS

2.3.1. Memory tables

2.3.2. IO Tables

2.3.3. File Tables

2.3.4. Process Tables

3. One or More Threads in a Process

3.1. saved thread context when not running

3.2. an execution stack

3.3. some per-thread static storage for local variables

3.4. access to the memory and resources of its process

3.5. an execution state (Running, Ready, etc.)

4. Processes

4.1. unit of resource allocation and a unit of protection

4.2. A virtual address space that holds the process image

4.3. Protected access to

4.3.1. processors

4.3.2. other processes

4.3.3. files

4.3.4. I/O resources

5. Processes and Threads

5.1. Resource Ownership

5.1.1. includes a virtual address space to hold the process image OS performs a protection function to prevent unwanted interference between processes with respect to resources

5.2. Scheduling/Execution

5.2.1. Follows an execution path that may be interleaved with other processes a process has an execution state

5.3. Multithreading

5.3.1. The ability of an OS to support multiple, concurrent paths of execution within a single process

5.4. unit of resource ownership is referred to as a process or task

5.5. unit of dispatching is referred to as a thread or lightweight process

6. Single Threaded Approaches

6.1. which the concept of a thread is not recognized,is referred to as a single-threaded approach

6.2. Example

6.2.1. MS-DOS

7. Multithreaded Approaches

7.1. A Java run-time environment is an example of a system of one process with multiple threads

8. OS Management of Application Execution

8.1. switched among multiple applications so all will appear to be progressing

8.2. Resources are made available to multiple applications

8.3. The processor and I/O devices can be used efficiently

9. A process can be defined as

9.1. a program in execution

9.2. an instance of a running program

9.3. the entity that can be assigned to, and executed on, a processor

9.4. a unit of activity characterized by a single sequential thread of execution, a current state, and an associated set of system resources

10. Process Elements

10.1. Program code

10.1.1. which may be shared with other processes that are executing the same progra

10.2. A set of data associated with that code

10.2.1. when the processor begins to execute the program code, we refer to this executing entity as a process

10.2.2. when the processor begins to execute the program code, we refer to this executing entity as a process

11. Process Control Block

11.1. Contains the process elements

11.2. Created and managed by the operating system

11.3. Key tool that allows support for multiple processes

12. Process State

12.1. Trace

12.1.1. sequence of instructions that execute for that process

12.1.2. showing how the traces of the various processes are interleaved

12.2. Dispatcher

12.2.1. small program that switches the processor from one process to another

13. Two-State Process Model

13.1. Running

13.2. Not-Running

14. Process Creation

14.1. Process spawning

14.1.1. when the OS creates a process at the explicit request of another process

14.2. Parent process

14.2.1. is the original, creating, process

14.3. Child process

14.3.1. is the new process

15. Process Termination

15.1. include a HALT instruction or an explicit OS service call for termination

15.2. the action of the user will indicate when the process is completed

16. Characteristics of a Suspended Process

16.1. process is not immediately available for execution

16.2. process may or may not be waiting on an event

16.3. process may not be removed from this state until the agent explicitly orders the removal

16.4. process was placed in a suspended state by an agent for the purpose of preventing its execution

17. Benefits of Threads

17.1. Takes less time to create a new thread than a process

17.2. Less time to terminate a thread than a process

17.3. Switching between two threads takes less time than switching between processes

17.4. Threads enhance efficiency in communication between programs