Chapter 4 Process and Threads
by Tan pay fen
1. OS Management of Application Execution
1.1. - Resource are made available to multiple applications. Process - Define as a program in execution and active entity with a program counter specifying the next instruction to be executed. - A program which is passive entity such as contents of a fill store on disk.
2. Process Control Block
2.1. - Contains the process element. - Crated and managed by OS. Process State - Trace : List the sequence of instruction that execute for process. - Dispatch : small program switches process from one to another.
3. Process Creation
3.1. - Occurs when a new process added to currently being managed process. - Process spawning : when the OS creates a process at the explicit request of another process. - Parent process : the original , creating, process. - Child process : the new process.
4. Single Threaded Approaches
4.1. - The concept of a thread is not recognized. - Example : MS-DOS.
5. Multithread Approaches
5.1. - A system of one process with multiple threads. - Example : Java run-time.
6. Operation System Control Structure
6.1. - Four different type tables maintained : 1. Memory Tables 2. I/O Tables 3. File Tables 4. Process Tables
7. Suspended Process
7.1. 1. New 2. Ready 3. Running 4. Blocked ( if necessary) 5. Suspend : A process that has been swapped out of main memory and back to Ready Step. 6. Exit.
8. Five-State Process Model
8.1. 1. New : A process is created 2. Ready : A process prepared to be executed when given chance. 3. Running : A process that being executed. 4. Blocked : Necessarily when a process cannot execute until some event occurs such as I/O completion and back to the Ready step. 5. Exit : A process that has finished its execution.
9. Two-State Process Model
9.1. - A process may be in one of two states which is Running or Not-running.
10. Processes and Threads
10.1. - A thread or lightweight process. - Multithreading : Ability of OS to support multiple task , concurrent paths of execution within a single process.
11. Process Termination
11.1. - A means or process to indicate its completion.